:root {
    --primary: #ebc982;
    --primary-light: #EBC47E;
    --bg-main: #0B1320;
    --bg-card: #121B2D;
    --accent: #1E293B;
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --white: #ffffff;
    --primary-content: #0B1320;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
.logo {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    line-height: 1.2;
}

h1 {
    font-size: 3rem;
    /* Fallback */
    font-size: clamp(2.5rem, 8vw, 5rem);
}

h2 {
    font-size: 2.5rem;
    /* Fallback */
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h3 {
    font-size: 1.5rem;
    /* Fallback */
    font-size: clamp(1.5rem, 3vw, 2rem);
}

.italic {
    font-style: italic;
    font-weight: 400;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 100px 0;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: calc(1rem + env(safe-area-inset-top, 0px)) 0 1rem;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.navbar.scrolled,
.navbar.menu-open {
    background: rgba(11, 19, 32, 0.95);
    padding: 1rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-img {
    height: 90px;
    width: auto;
    object-fit: contain;
    transition: var(--transition);
}

.nav-links {
    display: flex;
    gap: 3rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--primary);
    cursor: pointer;
    padding: 0.25rem;
    z-index: 1001;
}

/* Hamburger / Close icon toggle */
.mobile-toggle .close-icon {
    display: none;
}

.mobile-toggle.active .hamburger-icon {
    display: none;
}

.mobile-toggle.active .close-icon {
    display: block;
}

@media (max-width: 768px) {
    .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(18, 27, 45, 0.98);
        -webkit-backdrop-filter: blur(20px);
        backdrop-filter: blur(20px);
        padding: 0 2rem;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
        gap: 0;
        -webkit-overflow-scrolling: touch;
        text-align: center;
        border-top: 1px solid rgba(235, 201, 130, 0.15);
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.3s ease,
                    padding 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-links.open {
        max-height: 400px;
        opacity: 1;
        padding: 1.5rem 2rem 2rem;
    }

    .nav-link {
        font-size: 1.15rem;
        padding: 0.85rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        opacity: 0;
        transform: translateY(-10px);
        transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
    }

    .nav-links.open .nav-link {
        opacity: 1;
        transform: translateY(0);
    }

    .nav-links.open .nav-link:nth-child(1) { transition-delay: 0.05s; }
    .nav-links.open .nav-link:nth-child(2) { transition-delay: 0.1s; }
    .nav-links.open .nav-link:nth-child(3) { transition-delay: 0.15s; }
    .nav-links.open .nav-link:nth-child(4) { transition-delay: 0.2s; }

    .nav-link:last-child {
        border-bottom: none;
    }

    .mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .logo-img {
        height: 55px;
    }
}

/* Hero Section */
.hero {
    height: 100vh;
    height: 100svh;
    /* Safari iOS dynamic viewport */
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    flex-direction: column;
    -webkit-box-pack: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero-content {
    text-align: center;
    max-width: 900px;
}

.hero h1 {
    margin-bottom: 2rem;
    color: var(--primary);
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    border-radius: 100px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--primary-content);
    border: 2px solid var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-light);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(197, 147, 83, 0.3);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--primary-content);
    transform: translateY(-3px);
}

/* Stats */
.hero-stats {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--primary);
    padding: 1.5rem 0;
    color: var(--primary-content);
    padding-bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
}

.stats-container {
    display: flex;
    justify-content: space-around;
    max-width: 1200px;
    margin: 0 auto;
}

.stat-item {
    text-align: center;
}

.stat-num {
    display: block;
    font-size: 3rem;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-label {
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 2px;
    opacity: 0.8;
}

/* About Section */
.about {
    background: var(--bg-main);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
    align-items: center;
}

.about-card {
    background: var(--primary);
    color: var(--primary-content);
    padding: 4rem;
    border-radius: 40px;
}

.about-card h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.about-features {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.feature-item {
    display: flex;
    gap: 1.5rem;
}

.feature-icon {
    width: 50px;
    height: 50px;
    background: var(--bg-card);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
}

.feature-item h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
}

.feature-item p {
    color: var(--text-muted);
}

/* Services */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 5rem;
}

.section-header h2 {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

/* Services Carousel */
.carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 0 -1rem;
    /* Adjust for padding */
}

.carousel-container {
    overflow: hidden;
    width: 100%;
}

.services-grid {
    display: -webkit-box;
    display: flex;
    transition: transform 0.5s ease-in-out;
    gap: 2rem;
}

.service-card {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: 24px;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.05);
    flex: 0 0 calc(33.333% - 1.333rem);
    /* Default: 3 cards per view */
    min-width: 300px;
}

@media (max-width: 1024px) {
    .service-card {
        flex: 0 0 calc(50% - 1rem);
        /* 2 cards */
    }
}

@media (max-width: 768px) {
    .service-card {
        flex: 0 0 100%;
        /* 1 card */
    }
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow);
    border-color: var(--accent);
    background: var(--accent);
}

.service-icon {
    color: var(--primary);
    margin-bottom: 2rem;
}

.service-icon i {
    width: 48px;
    height: 48px;
}

.service-card h3 {
    font-size: 1.75rem;
    margin-bottom: 1.25rem;
    font-family: 'Playfair Display', serif;
    letter-spacing: -0.02em;
    color: var(--primary);
    font-weight: 700;
}

.service-card p {
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-weight: 400;
    font-size: 1.05rem;
    line-height: 1.5;
}

.learn-more {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--primary);
    font-weight: 700;
    font-size: 1.1rem;
    transition: var(--transition);
}

.learn-more:hover {
    gap: 1rem;
}

/* Carousel Controls */
.carousel-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    background: var(--bg-card);
    color: var(--primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10;
    flex-shrink: 0;
}

.carousel-btn:hover {
    background: var(--primary);
    color: var(--primary-content);
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 3rem;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #d1d5db;
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background: var(--primary);
    width: 25px;
    border-radius: 10px;
}

.relative {
    position: relative;
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 6rem;
}

.contact-info h2 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 2rem;
    color: var(--primary);
}

.info-list {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-muted);
}

.info-item i {
    color: var(--primary);
}

.contact-form {
    background: var(--bg-card);
    padding: 4rem;
    border-radius: 40px;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--bg-main);
    color: var(--text-main);
    border-radius: 12px;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(197, 147, 83, 0.2);
}

.btn-block {
    width: 100%;
    margin-top: 1rem;
}

/* Footer */
.footer {
    padding: 4rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: var(--bg-main);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-logo {
    font-size: 1.5rem;
    color: var(--primary);
    font-weight: 700;
}

.footer-copy {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-links a {
    color: var(--primary);
    transition: var(--transition);
}

.social-links a:hover {
    transform: translateY(-3px);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 {
    transition-delay: 0.2s;
}

.reveal-delay-2 {
    transition-delay: 0.4s;
}

.reveal-delay-3 {
    transition-delay: 0.6s;
}

/* Responsive */
@media (max-width: 1024px) {

    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 4rem;
    }

    .hero h1 {
        font-size: 4rem;
    }
}

@media (max-width: 768px) {
    section {
        padding: 60px 0;
    }

    .logo-img {
        height: 65px;
    }

    .hero {
        height: auto;
        min-height: 100vh;
        padding-top: 140px;
        padding-bottom: 60px;
    }

    .hero h1 {
        font-size: 2.75rem;
        margin-bottom: 1.5rem;
    }

    .hero p {
        font-size: 1.1rem;
        margin-bottom: 2.5rem;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .hero-stats {
        position: static;
        margin-top: 4rem;
        padding: 4rem 1rem;
    }

    .stats-container {
        flex-direction: column;
        gap: 3.5rem;
    }

    .stat-num {
        font-size: 2.5rem;
    }

    .about-card {
        padding: 2.5rem;
    }

    .about-card h2 {
        font-size: 2rem;
    }

    /* Carousel mobile adjustment */
    .carousel-wrapper {
        margin: 0;
    }

    .carousel-btn {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        background: rgba(255, 255, 255, 0.9);
        width: 40px;
        height: 40px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }

    .carousel-btn.prev {
        left: -10px;
    }

    .carousel-btn.next {
        right: -10px;
    }

    .service-card {
        padding: 2.5rem 2rem;
    }

    .contact-form {
        padding: 2.5rem;
    }

    .contact-info h2 {
        font-size: 2.5rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
        padding-bottom: env(safe-area-inset-bottom, 2rem);
    }
}

/* Tablet / Foldable Tier (480px - 1024px) */
@media (min-width: 481px) and (max-width: 1024px) {
    .hero {
        padding-top: 160px;
    }

    .stats-container {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
        padding: 0 2rem;
    }

    .hero-stats {
        position: relative;
        margin-top: 4rem;
    }

    .service-card {
        flex: 0 0 calc(50% - 1rem);
        /* 2 cards */
    }

    .about-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 4rem;
    }
}

/* Hard caps for Hubs and Ultra-Wide Tablet views */
@media (min-width: 1200px) {
    .container {
        padding: 0;
    }
}

/* Toast Notification */
@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes toastOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }

    to {
        opacity: 0;
        transform: translateY(20px);
    }
}

.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--primary);
    color: var(--white);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    min-width: 280px;
    max-width: 380px;
}

.toast.show {
    animation: toastIn 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    pointer-events: auto;
}

.toast.hide {
    animation: toastOut 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    font-size: 0.95rem;
    line-height: 1.4;
}

.toast-content i {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .toast {
        right: 16px;
        left: 16px;
        bottom: 20px;
        justify-content: center;
        text-align: center;
        min-width: unset;
        max-width: unset;
    }
}