/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Global dark mode transition — applied to all elements at once */
*,
*::before,
*::after {
    transition: background-color 0.4s ease, color 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

:root {
    --primary-color: #1B3A6B;
    --secondary-color: #FDB813;
    --text-dark: #1B3A6B;
    --text-light: #5A6C84;
    --bg-light: #F7F9FC;
    --bg-white: #FFFFFF;
    --accent-color: #FDB813;
    --success-color: #34C759;
    --border-color: #D2D2D7;
    --shadow: 0 4px 6px rgba(27, 58, 107, 0.1);
    --shadow-lg: 0 10px 30px rgba(27, 58, 107, 0.15);
    --yellow-light: #FFF8E1;
    --navy-dark: #0F1F3D;
    --navbar-bg: rgba(255, 255, 255, 0.95);
    --ease-out-expo: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Theme Overrides */
[data-theme="dark"] {
    --primary-color: #4A90D9;
    --secondary-color: #FDB813;
    --text-dark: #E8EDF5;
    --text-light: #A0B1C5;
    --bg-light: #1a2744;
    --bg-white: #0F1F3D;
    --accent-color: #FDB813;
    --success-color: #34C759;
    --border-color: #3A4F6E;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.4);
    --yellow-light: #2A2510;
    --navy-dark: #0A1628;
    --navbar-bg: rgba(15, 31, 61, 0.95);
}

[data-theme="dark"] .hero {
    background: linear-gradient(135deg, #0A1628 0%, #1a2744 50%, #0A1628 100%);
}

[data-theme="dark"] .nav-menu {
    background-color: var(--bg-white);
}

[data-theme="dark"] .skill-tag {
    background-color: #243352;
    border-color: var(--secondary-color);
}

[data-theme="dark"] .tag {
    background-color: #243352;
}

[data-theme="dark"] .booking-error {
    background: #3D1F1F;
    color: #E74C3C;
}

[data-theme="dark"] .booking-input {
    background-color: #243352;
    color: var(--text-dark);
    border-color: var(--border-color);
}

[data-theme="dark"] .timezone-picker select {
    background-color: #243352;
    color: var(--text-dark);
}

[data-theme="dark"] .hamburger span {
    background-color: var(--text-dark);
}

[data-theme="dark"] .progress-step .step-number {
    background-color: #243352;
    color: var(--text-light);
}

[data-theme="dark"] .progress-step.active .step-number,
[data-theme="dark"] .progress-step.completed .step-number {
    background-color: var(--secondary-color);
    color: var(--primary-color);
}

[data-theme="dark"] .progress-line {
    background-color: #3A4F6E;
}

/* Nav Controls (theme + lang toggles) */
.nav-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.theme-toggle,
.lang-toggle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: none;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    transition: all 0.3s var(--ease-out-expo);
    box-shadow: 0 2px 8px rgba(27, 58, 107, 0.2);
}

.theme-toggle:hover,
.lang-toggle:hover {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(253, 184, 19, 0.4);
}

.theme-toggle:active,
.lang-toggle:active {
    transform: scale(0.95);
}

.theme-toggle i {
    font-size: 1.1rem;
}

.lang-select {
    height: 38px;
    padding: 0 0.5rem;
    border-radius: 50px;
    border: none;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(27, 58, 107, 0.2);
    transition: all 0.3s var(--ease-out-expo);
    -webkit-appearance: none;
    appearance: none;
    text-align: center;
}

.lang-select:hover {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    box-shadow: 0 4px 15px rgba(253, 184, 19, 0.4);
}

.lang-select:focus {
    outline: none;
}

.lang-select option {
    background-color: var(--bg-white);
    color: var(--text-dark);
    font-weight: 600;
}

/* RTL support for Farsi */
[dir="rtl"] .timeline-item {
    padding-left: 0;
    padding-right: 40px;
}

[dir="rtl"] .timeline-marker {
    left: auto;
    right: 0;
}

[dir="rtl"] .timeline-highlights li {
    padding-left: 0;
    padding-right: 1.5rem;
}

[dir="rtl"] .timeline-highlights li::before {
    left: auto;
    right: 0;
    content: '◂';
}

[dir="rtl"] .timeline-period i,
[dir="rtl"] .timeline-location i {
    margin-right: 0;
    margin-left: 0.5rem;
}

[dir="rtl"] .info-item {
    direction: rtl;
}

[dir="rtl"] .selected-slot-summary {
    border-left: none;
    border-right: 4px solid var(--secondary-color);
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 72px;
    /* Snap to sections — proximity lets long sections scroll freely */
    scroll-snap-type: y proximity;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Page content wrapper for non-hero pages */
.page-content {
    padding-top: 90px;
    min-height: calc(100vh - 120px);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: var(--navbar-bg);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 1rem 0;
    transition: transform 0.35s var(--ease-out-expo);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Active nav link */
.nav-menu a.active-link {
    color: var(--primary-color);
    position: relative;
}

.nav-menu a.active-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
}

/* One-pager: each section fills at least the full viewport and snaps into view */
.page-section {
    min-height: 100vh;
    scroll-snap-align: start;
    scroll-margin-top: 72px;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--text-dark);
    margin: 3px 0;
    transition: 0.3s;
}

/* Dropdown Navigation */
.nav-dropdown {
    position: relative;
    /* Extend hover zone below so mouse can reach the dropdown without a gap */
    padding-bottom: 14px;
    margin-bottom: -14px;
}

.nav-dropdown-toggle {
    display: flex !important;
    align-items: center;
    gap: 0.3rem;
    cursor: pointer;
    user-select: none;
}

.nav-dropdown-toggle .fa-chevron-down {
    font-size: 0.62rem;
    transition: transform 0.25s ease;
}

.nav-dropdown:hover .fa-chevron-down,
.nav-dropdown.open .fa-chevron-down {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    min-width: 150px;
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(27, 58, 107, 0.18);
    /* padding-top creates the visual gap; the li hover zone covers it */
    padding: 8px 0.4rem 0.4rem;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    z-index: 1010;
    border: 1px solid var(--border-color);
    pointer-events: none;
}

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 6px solid var(--border-color);
}

.dropdown-menu::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 6px solid var(--bg-white);
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown.open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
    pointer-events: all;
}

.dropdown-menu li { list-style: none; }

.dropdown-menu li a {
    display: block;
    padding: 0.45rem 1rem;
    white-space: nowrap;
    border-radius: 8px;
    transition: background-color 0.15s ease, color 0.15s ease;
    font-size: 0.9rem;
    font-weight: 500;
}

.dropdown-menu li a:hover,
.dropdown-menu li a.active-link {
    background-color: var(--bg-light);
    color: var(--primary-color) !important;
}

.nav-dropdown-active > a.nav-dropdown-toggle {
    color: var(--primary-color);
}

[data-theme="dark"] .dropdown-menu { box-shadow: 0 8px 32px rgba(0,0,0,0.5); }
[data-theme="dark"] .dropdown-menu::after { border-bottom-color: var(--bg-white); }
[data-theme="dark"] .dropdown-menu li a:hover,
[data-theme="dark"] .dropdown-menu li a.active-link { background-color: rgba(255,255,255,0.08); }


/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #1B3A6B 0%, #2C5282 25%, #1B3A6B 50%, #2C5282 75%, #1B3A6B 100%);
    background-size: 300% 300%;
    animation: heroGradient 12s ease infinite;
    color: white;
    padding-top: 80px;
}

.hero-content {
    text-align: center;
    animation: heroFloat 5s ease-in-out infinite;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
}

.highlight {
    background: linear-gradient(120deg, #FDB813 0%, #FFD700 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmerGlow 3s ease-in-out infinite;
}

.hero-subtitle {
    font-size: 2rem;
    font-weight: 400;
    margin-bottom: 1rem;
    opacity: 0.9;
    animation: fadeInUp 0.8s ease 0.2s backwards;
}

.hero-description {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem;
    opacity: 0.85;
    animation: fadeInUp 0.8s ease 0.4s backwards;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease 0.6s backwards;
}

.btn {
    padding: 0.875rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s var(--ease-out-expo);
    display: inline-block;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    font-weight: 700;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(253, 184, 19, 0.4);
    background-color: #FFD700;
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid var(--secondary-color);
}

.btn-secondary:hover {
    background-color: var(--secondary-color);
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

.social-links a {
    color: white;
    font-size: 1.8rem;
    transition: all 0.3s var(--ease-out-expo);
    animation: bounceIn 0.6s var(--ease-out-expo) backwards;
}
.social-links a:nth-child(1) { animation-delay: 0.8s; }
.social-links a:nth-child(2) { animation-delay: 0.95s; }
.social-links a:nth-child(3) { animation-delay: 1.1s; }

.social-links a:hover {
    transform: translateY(-3px);
    opacity: 0.8;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.5rem;
    text-decoration: none;
    animation: scrollBounce 2s ease-in-out infinite;
    transition: color 0.3s ease;
}

.scroll-indicator:hover {
    color: var(--secondary-color);
}

@keyframes scrollBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* Page content wrapper for subpages */
.page-content {
    padding-top: 100px;
}

/* Section Styles */
section {
    padding: 5rem 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    color: var(--text-dark);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 4px;
    background: var(--secondary-color);
    border-radius: 2px;
    transition: width 0.6s var(--ease-out-expo);
}

.section-title.revealed::after {
    width: 60px;
}

/* About Section */
.about {
    background-color: var(--bg-light);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-light);
    line-height: 1.8;
}

.about-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background-color: var(--bg-white);
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: box-shadow 0.3s ease;
}

.info-item i {
    color: var(--primary-color);
    font-size: 1.5rem;
}

/* Experience Section */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto 3rem;
}

.timeline-item {
    position: relative;
    padding-left: 40px;
    margin-bottom: 2rem;
}

.timeline-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 20px;
    height: 20px;
    background-color: var(--primary-color);
    border-radius: 50%;
    border: 4px solid var(--bg-white);
    box-shadow: 0 0 0 4px var(--primary-color);
}

.timeline-content {
    background-color: var(--bg-white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: box-shadow 0.3s ease;
}

.timeline-content h3 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.timeline-content h4 {
    color: var(--text-dark);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.timeline-period {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.role-type {
    color: var(--text-light);
    font-weight: 400;
    font-size: 0.9em;
}

.timeline-period i {
    margin-right: 0.5rem;
    color: var(--secondary-color);
}

.timeline-location {
    color: var(--text-light);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.timeline-location i {
    margin-right: 0.5rem;
}

.timeline-highlights {
    list-style: none;
    padding-left: 0;
}

.timeline-highlights li {
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    position: relative;
    color: var(--text-light);
    line-height: 1.6;
}

.timeline-highlights li::before {
    content: '\25B8';
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

.achievements {
    margin-top: 3rem;
}

.achievements h3 {
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
    color: var(--text-dark);
}

.achievement-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.achievement-card {
    background-color: var(--bg-white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s var(--ease-out-expo),
                box-shadow 0.3s var(--ease-out-expo),
                background-color 0.4s ease;
}

.achievement-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg), 0 0 20px rgba(253, 184, 19, 0.15);
}

.achievement-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.achievement-card h4 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.achievement-card p {
    color: var(--text-light);
}

/* Projects Section */
.projects {
    background-color: var(--bg-light);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.project-card {
    background-color: var(--bg-white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    transition: transform 0.4s var(--ease-out-expo),
                box-shadow 0.4s var(--ease-out-expo),
                background-color 0.4s ease;
    transform-style: preserve-3d;
    perspective: 800px;
}

.project-card:hover {
    transform: translateY(-8px) rotateX(2deg) rotateY(-2deg);
    box-shadow: var(--shadow-lg), 0 0 25px rgba(253, 184, 19, 0.15);
}

.project-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.project-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.project-card p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background-color: var(--bg-light);
    color: var(--primary-color);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.skill-category {
    background-color: var(--bg-white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    transition: transform 0.3s var(--ease-out-expo),
                box-shadow 0.3s var(--ease-out-expo),
                background-color 0.4s ease;
}

.skill-category:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg), 0 0 20px rgba(253, 184, 19, 0.15);
}

.skill-category h3 {
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

.skill-category h3 i {
    color: var(--primary-color);
    margin-right: 0.5rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.skill-tag {
    background-color: var(--primary-color);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 2px solid var(--secondary-color);
    transition: all 0.3s var(--ease-out-expo);
}

.skill-tag:hover {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    transform: translateY(-3px) scale(1.08);
    box-shadow: 0 4px 15px rgba(253, 184, 19, 0.35);
}

.volunteer-section {
    margin-top: 3rem;
}

.volunteer-section h3 {
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
    color: var(--text-dark);
}

.volunteer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.volunteer-card {
    background-color: var(--bg-white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s var(--ease-out-expo),
                box-shadow 0.3s var(--ease-out-expo),
                background-color 0.4s ease;
}

.volunteer-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg), 0 0 20px rgba(253, 184, 19, 0.15);
}

.volunteer-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.volunteer-card h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.volunteer-card p {
    color: var(--text-light);
}

/* Contact Section */
.contact {
    background-color: var(--bg-light);
}

.contact-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.contact-description {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 3rem;
}

.contact-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.contact-card {
    background-color: var(--bg-white);
    padding: 2.5rem 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    transition: transform 0.3s var(--ease-out-expo),
                box-shadow 0.3s var(--ease-out-expo),
                background-color 0.4s ease;
    text-decoration: none;
    color: var(--text-dark);
    display: block;
}

.contact-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg), 0 0 20px rgba(253, 184, 19, 0.15);
}

.contact-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.contact-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.contact-card p {
    color: var(--text-light);
}

/* ===== Booking Section ===== */
.booking {
    background: linear-gradient(160deg, var(--bg-white) 0%, var(--bg-light) 50%, var(--bg-white) 100%);
    transition: background 0.4s ease;
}

.booking-description {
    text-align: center;
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Booking Progress Indicator */
.booking-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    max-width: 500px;
    margin: 0 auto 2.5rem;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.progress-step .step-number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    background-color: var(--bg-light);
    color: var(--text-light);
    border: 2px solid var(--border-color);
    transition: all 0.4s var(--ease-out-expo);
}

.progress-step span {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-light);
    transition: color 0.4s ease;
    white-space: nowrap;
}

.progress-step.active .step-number,
.progress-step.completed .step-number {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    border-color: var(--secondary-color);
    box-shadow: 0 2px 10px rgba(253, 184, 19, 0.3);
}

.progress-step.active span,
.progress-step.completed span {
    color: var(--text-dark);
}

.progress-line {
    flex: 1;
    height: 3px;
    background-color: var(--border-color);
    margin: 0 0.75rem;
    margin-bottom: 1.5rem;
    border-radius: 2px;
    position: relative;
    overflow: hidden;
}

.progress-line.filled {
    background-color: var(--secondary-color);
}

.timezone-picker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.timezone-picker i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.timezone-picker select {
    padding: 0.6rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text-dark);
    background-color: var(--bg-white);
    cursor: pointer;
    min-width: 280px;
    transition: border-color 0.3s var(--ease-out-expo),
                box-shadow 0.3s var(--ease-out-expo);
}

.timezone-picker select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(27, 58, 107, 0.1);
}

.booking-widget {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.booking-calendar {
    background-color: var(--bg-white);
    border-radius: 15px;
    box-shadow: var(--shadow);
    padding: 2rem;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.calendar-header h3 {
    font-size: 1.2rem;
    color: var(--text-dark);
}

.cal-nav-btn {
    background: none;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
    transition: all 0.2s var(--ease-out-expo);
}

.cal-nav-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background-color: var(--bg-light);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    margin-bottom: 0.75rem;
}

.calendar-weekdays span {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-light);
    padding: 0.5rem 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
}

.cal-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.9rem;
    cursor: default;
    color: var(--border-color);
    transition: all 0.2s var(--ease-out-expo);
    position: relative;
    overflow: hidden;
}

.cal-day .ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(253, 184, 19, 0.35);
    animation: ripple 0.5s ease-out forwards;
    pointer-events: none;
    width: 10px;
    height: 10px;
}

.cal-day.available {
    color: var(--text-dark);
    cursor: pointer;
    font-weight: 500;
}

.cal-day.available:hover {
    background-color: var(--bg-light);
    transform: scale(1.1);
}

.cal-day.selected {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
}

.cal-day.today {
    border: 2px solid var(--secondary-color);
}

.booking-slots {
    background-color: var(--bg-white);
    border-radius: 15px;
    box-shadow: var(--shadow);
    padding: 1.5rem;
    max-height: 420px;
    overflow-y: auto;
}

.slots-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 200px;
    color: var(--text-light);
    text-align: center;
}

.slots-placeholder i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--border-color);
}

.slots-header {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--bg-light);
}

.slot-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.85rem 1rem;
    margin-bottom: 0.5rem;
    border: 2px solid var(--primary-color);
    border-radius: 10px;
    background: var(--bg-white);
    color: var(--primary-color);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s var(--ease-out-expo);
    text-align: center;
    animation: slideInFromRight 0.4s var(--ease-out-expo) both;
    animation-delay: calc(var(--slot-i, 0) * 0.05s);
}

.slot-btn .fa-clock {
    font-size: 0.85rem;
    opacity: 0.7;
}

.slot-btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateX(-3px);
}

.slot-btn.selected {
    background-color: var(--primary-color);
    color: white;
}

.no-slots {
    text-align: center;
    color: var(--text-light);
    padding: 2rem 1rem;
}

.no-slots i {
    font-size: 2rem;
    margin-bottom: 0.75rem;
    display: block;
    color: var(--border-color);
}

.booking-confirm {
    margin-top: 1rem;
    animation: slideUpIn 0.4s var(--ease-out-expo) both;
}

/* Floating label input group */
.booking-input-group {
    position: relative;
    margin-bottom: 0.75rem;
}

.booking-input-group .booking-input {
    margin-bottom: 0;
    padding-top: 1.1rem;
    padding-bottom: 0.6rem;
}

.booking-input-group .booking-label {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.95rem;
    color: var(--text-light);
    pointer-events: none;
    transition: all 0.25s var(--ease-out-expo);
    background: transparent;
}

.booking-input-group .booking-input:focus ~ .booking-label,
.booking-input-group .booking-input:not(:placeholder-shown) ~ .booking-label {
    top: 0.35rem;
    transform: translateY(0);
    font-size: 0.7rem;
    color: var(--primary-color);
    font-weight: 600;
}

.booking-input {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    margin-bottom: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text-dark);
    background-color: var(--bg-white);
    transition: border-color 0.3s var(--ease-out-expo),
                box-shadow 0.3s var(--ease-out-expo);
}

.booking-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(27, 58, 107, 0.12);
}

[data-theme="dark"] .booking-input:focus {
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.2);
}

.confirm-btn {
    display: block;
    width: 100%;
    padding: 0.875rem 2rem;
    border: none;
    border-radius: 50px;
    background-color: var(--secondary-color);
    color: var(--primary-color);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s var(--ease-out-expo);
}

.confirm-btn:hover:not(:disabled) {
    background-color: #FFD700;
    box-shadow: 0 10px 30px rgba(253, 184, 19, 0.4);
    transform: translateY(-2px);
}

.confirm-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0.4rem 0;
    margin-bottom: 1rem;
    transition: opacity 0.2s ease;
}

.back-btn:hover {
    opacity: 0.7;
}

.selected-slot-summary {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background-color: var(--bg-light);
    border-radius: 10px;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.selected-slot-summary i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.booking-error {
    background: #fff3f3;
    color: #c0392b;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: shake 0.5s ease;
}

.booking-success {
    text-align: center;
    padding: 2.5rem 1rem;
    position: relative;
    overflow: hidden;
}

.booking-success::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle, var(--secondary-color) 2px, transparent 2px),
        radial-gradient(circle, var(--primary-color) 1.5px, transparent 1.5px),
        radial-gradient(circle, var(--success-color) 2px, transparent 2px),
        radial-gradient(circle, var(--secondary-color) 1px, transparent 1px),
        radial-gradient(circle, var(--success-color) 1.5px, transparent 1.5px);
    background-size: 60px 60px, 40px 40px, 80px 80px, 50px 50px, 70px 70px;
    background-position: 0 0, 20px 20px, 40px 10px, 10px 40px, 55px 35px;
    opacity: 0.12;
    pointer-events: none;
    animation: confettiBgDrift 8s linear infinite;
}

@keyframes confettiBgDrift {
    0% { background-position: 0 0, 20px 20px, 40px 10px, 10px 40px, 55px 35px; }
    100% { background-position: 60px 60px, 80px 80px, 120px 70px, 70px 100px, 125px 95px; }
}

.booking-success i.fa-check-circle {
    font-size: 5rem;
    color: #27ae60;
    margin-bottom: 1.25rem;
    display: inline-block;
    animation: checkBounce 0.6s var(--ease-out-expo) both;
}

.booking-success h3 {
    font-size: 1.6rem;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
    animation: fadeInUp 0.5s 0.2s both;
}

.booking-success p {
    color: var(--text-light);
    margin-bottom: 0.5rem;
    line-height: 1.6;
    animation: fadeInUp 0.5s 0.3s both;
}

.meet-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 1rem 0;
    padding: 0.75rem 1.5rem;
    background: var(--primary-color);
    color: white;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s var(--ease-out-expo);
}

.meet-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

@media (max-width: 768px) {
    .booking-widget {
        grid-template-columns: 1fr;
    }

    .booking-slots {
        max-height: 300px;
    }

    .booking-progress {
        max-width: 100%;
        padding: 0 1rem;
    }

    .progress-step span {
        font-size: 0.7rem;
    }
}

/* Footer */
.footer {
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    padding: 2rem 0;
}

.footer p {
    margin: 0.5rem 0;
}

.footer i {
    color: var(--secondary-color);
}

/* ===== Animations & Keyframes ===== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes heroFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes heroGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes shimmerGlow {
    0%, 100% {
        filter: brightness(1) drop-shadow(0 0 0px transparent);
    }
    50% {
        filter: brightness(1.15) drop-shadow(0 0 12px rgba(253, 184, 19, 0.5));
    }
}

@keyframes underlineReveal {
    from { width: 0; }
    to { width: 60px; }
}

@keyframes skillPop {
    0% {
        opacity: 0;
        transform: scale(0.7);
    }
    60% {
        transform: scale(1.08);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.8);
    }
    60% {
        transform: translateY(-4px) scale(1.05);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes slideInFromRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideUpIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes checkBounce {
    0% { transform: scale(0); }
    50% { transform: scale(1.3); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
    20%, 40%, 60%, 80% { transform: translateX(4px); }
}

@keyframes ripple {
    0% {
        transform: scale(0);
        opacity: 0.5;
    }
    100% {
        transform: scale(4);
        opacity: 0;
    }
}

@keyframes confettiFloat {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(-60px) rotate(360deg);
        opacity: 0;
    }
}

/* ===== Scroll-reveal system ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s var(--ease-out-expo),
                transform 0.6s var(--ease-out-expo);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.6s var(--ease-out-expo),
                transform 0.6s var(--ease-out-expo);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.6s var(--ease-out-expo),
                transform 0.6s var(--ease-out-expo);
}

.reveal-left.revealed,
.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

/* Staggered children in grids */
.reveal-stagger > .reveal {
    transition-delay: calc(var(--reveal-i, 0) * 0.1s);
}

/* ===== Skill tag viewport animation ===== */
.skill-tag.revealed {
    animation: skillPop 0.5s var(--ease-out-expo) both;
    animation-delay: calc(var(--reveal-i, 0) * 0.06s);
}

/* ===== Prefers reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .hero-content {
        animation: none;
    }

    .hero {
        animation: none;
    }

    .highlight {
        animation: none;
    }

    .reveal,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
    }

    .skill-tag.revealed {
        animation: none;
        opacity: 1;
    }

    .social-links a {
        animation: none;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-controls {
        order: 1;
        margin-left: auto;
        margin-right: 1rem;
    }

    .hamburger {
        order: 2;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--bg-white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-dropdown .dropdown-menu {
        position: static;
        transform: none !important;
        box-shadow: none;
        border: none;
        border-radius: 0;
        padding: 0 0 0.25rem 0;
        background: transparent;
        opacity: 1;
        visibility: visible;
        display: none;
        pointer-events: all;
        min-width: unset;
    }

    .dropdown-menu::before,
    .dropdown-menu::after { display: none; }

    .nav-dropdown.open .dropdown-menu { display: block; }

    /* Center dropdown toggles to match direct nav links */
    .nav-dropdown-toggle {
        justify-content: center;
        width: 100%;
    }

    .dropdown-menu li a {
        font-size: 0.85rem;
        color: var(--text-light);
        padding: 0.3rem 1rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.5rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 80%;
        max-width: 300px;
    }

    .section-title {
        font-size: 2rem;
    }

    .about-info {
        grid-template-columns: 1fr;
    }

    .skills-grid,
    .projects-grid,
    .achievement-grid,
    .volunteer-grid,
    .contact-methods {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    /* Disable scroll-snap on phones — sections taller than viewport get stuck */
    html {
        scroll-snap-type: none;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-description {
        font-size: 0.95rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .btn {
        width: 90%;
        padding: 0.75rem 1.5rem;
    }

    .container {
        padding: 0 16px;
    }

    .page-section {
        min-height: auto;
        padding-top: 5rem;
        padding-bottom: 4rem;
    }

    .hero.page-section {
        min-height: 100vh;
    }

    .timeline-item {
        padding-left: 28px;
    }

    .timeline-content {
        padding: 1rem;
    }

    .timeline-content h3 {
        font-size: 1.1rem;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .contact-methods {
        grid-template-columns: 1fr 1fr;
    }

    .achievement-grid,
    .volunteer-grid {
        grid-template-columns: 1fr;
    }
}
