:root {
    --bg-color: #fbfbfd;
    --text-color: #1d1d1f;
    --text-muted: #86868b;
    --primary-color: #0066cc;
    --primary-hover: #0077ed;
    --nav-bg: rgba(251, 251, 253, 0.8);
    --border-radius: 12px;
    --transition-speed: 0.3s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    padding-top: 56px; /* height of fixed navbar */
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-speed);
}

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

/* Navbar styles defined in DRAWER section below */



/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 30px;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    border: none;
}

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

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

.btn-link {
    color: var(--primary-color);
    padding: 12px 0;
}
.btn-link:hover {
    color: var(--primary-hover);
}

/* Hero Section */
.hero {
    padding-top: 150px;
    padding-bottom: 80px;
    text-align: center;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 700;
    letter-spacing: -1.5px;
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.3rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 30px;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    align-items: center;
}

/* Features */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding-bottom: 100px;
}

.feature-box {
    background: #ffffff;
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    text-align: center;
}

.feature-box h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.feature-box p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Footer */
.footer {
    border-top: 1px solid rgba(0,0,0,0.05);
    padding: 30px 0;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }

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

/* Auth Module */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: calc(100vh - 56px);
    padding: 30px 20px;
    margin-top: 0;
}

.auth-box {
    background: #ffffff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.06);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.auth-box h2 {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.auth-box p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 25px;
}

.input-group {
    margin-bottom: 15px;
}

.input-group input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.2s;
    font-family: inherit;
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.btn-block {
    width: 100%;
    display: block;
}

.auth-footer {
    margin-top: 20px;
    font-size: 0.85rem;
}

.auth-footer a {
    color: var(--primary-color);
}

.alert {
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.alert-error {
    background-color: #fdf2f2;
    color: #d92d20;
    border: 1px solid #f9d9d9;
}

/* Page Layouts & Typography */
.section-padding {
    padding: 100px 0;
}
.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: -1px;
}
.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 50px;
}
.text-center { text-align: center; }

/* Grid Layouts */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    align-items: center;
}
.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

/* UI Cards (Testimonials, etc) */
.card {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.04);
}
.testimonial-text {
    font-size: 1.1rem;
    font-style: italic;
    margin-bottom: 20px;
    color: var(--text-color);
}
.testimonial-author {
    font-weight: 600;
    color: var(--primary-color);
}

/* Forms */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.form-control {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #e5e5ea;
    border-radius: 12px;
    font-size: 1rem;
    font-family: inherit;
    background: #fafafa;
    transition: all 0.3s ease;
}
.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(0, 102, 204, 0.1);
}
textarea.form-control {
    min-height: 150px;
    resize: vertical;
}

/* Workflow */
.workflow-step {
    text-align: center;
    padding: 30px;
    position: relative;
}
.step-number {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 20px;
}

/* Portfolio Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}
.gallery-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    height: 300px;
    background: #eaeaea;
}
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 30px;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.gallery-item:hover img {
    transform: scale(1.05);
}
.gallery-item:hover .gallery-overlay {
    opacity: 1;
}
.gallery-title {
    color: white;
    font-size: 1.4rem;
    font-weight: 600;
}
.gallery-cat {
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}


/* ============================================
   NAVBAR - NEW DESIGN
   ============================================ */

/* Remove old navbar styles that conflict */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 900;
    background: rgba(255,255,255,0.92);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(0,0,0,0.08);
}

.nav-inner {
    display: flex;
    align-items: center;
    height: 56px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
    gap: 16px;
}

/* Hamburger button */
.nav-burger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    transition: background 0.2s;
}
.nav-burger:hover { background: rgba(0,0,0,0.06); }
.nav-burger span {
    display: block;
    width: 22px;
    height: 2px;
    background: #1d1d1f;
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}
/* Animate to X when active */
.nav-burger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-burger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Brand */
.brand { display: flex; align-items: center; }
.brand-logo { height: 36px; object-fit: contain; }
.brand-text { font-weight: 700; font-size: 1.1rem; letter-spacing: -0.3px; }

/* Desktop nav */
.desktop-nav {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-left: auto;
    font-size: 0.875rem;
    font-weight: 500;
}
.desktop-nav a { opacity: 0.75; transition: opacity 0.2s; }
.desktop-nav a:hover { opacity: 1; }
.nav-btn {
    padding: 7px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    opacity: 1 !important;
    transition: all 0.2s;
}
.nav-btn-primary { background: #0071e3; color: #fff; }
.nav-btn-primary:hover { background: #005bb5; }
.nav-btn-danger { background: rgba(220,53,69,0.1); color: #dc3545; }
.nav-btn-danger:hover { background: rgba(220,53,69,0.2); }

/* ============================================
   DRAWER (SIDE MENU) — works on ALL browsers
   ============================================ */

/* Dark overlay behind drawer */
.drawer-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1100;
    opacity: 0;
    transition: opacity 0.3s ease;
    -webkit-tap-highlight-color: transparent;
}
.drawer-overlay.open {
    display: block;
    opacity: 1;
}

/* Side Drawer Panel */
.drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 285px;
    max-width: 85vw;
    height: 100%;
    height: 100dvh; /* dynamic viewport height for iOS */
    background: #fff;
    z-index: 1200;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-overflow-scrolling: touch; /* iOS smooth scroll */
    box-shadow: 4px 0 24px rgba(0,0,0,0.15);
    will-change: transform;
}
.drawer.open {
    transform: translateX(0);
}

/* Drawer Header */
.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #182E4B;
    color: #fff;
    flex-shrink: 0;
    min-height: 60px;
}
.drawer-title {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.2px;
}
.drawer-close {
    background: rgba(255,255,255,0.15);
    border: none;
    color: #fff;
    cursor: pointer;
    border-radius: 8px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    flex-shrink: 0;
}
.drawer-close:hover { background: rgba(255,255,255,0.25); }
.drawer-close:active { background: rgba(255,255,255,0.1); }

/* User Badge (when logged in) */
.drawer-user-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: #f0f4f8;
    border-bottom: 1px solid #e5e5ea;
    flex-shrink: 0;
}
.drawer-avatar {
    width: 42px;
    height: 42px;
    background: #182E4B;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    flex-shrink: 0;
}
.drawer-user-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1d1d1f;
}
.drawer-user-role {
    font-size: 0.75rem;
    color: #86868b;
    margin-top: 1px;
}

/* Drawer Nav Links */
.drawer-nav {
    display: flex;
    flex-direction: column;
    padding: 8px 0;
    flex: 1;
}
.drawer-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    color: #1d1d1f;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s;
    -webkit-tap-highlight-color: transparent;
    cursor: pointer;
}
.drawer-link:hover,
.drawer-link:active { background: #f5f5f7; }
.drawer-link svg { flex-shrink: 0; opacity: 0.6; }
.drawer-link-primary { color: #0071e3; }
.drawer-link-primary svg { opacity: 1; color: #0071e3; }
.drawer-link-danger { color: #dc3545; }
.drawer-link-danger svg { opacity: 1; color: #dc3545; }

.drawer-divider {
    height: 1px;
    background: #e5e5ea;
    margin: 6px 20px;
}

/* ============================================
   MOBILE MEDIA QUERY
   ============================================ */
@media screen and (max-width: 768px) {
    /* Navbar: show burger, hide desktop menu */
    .nav-burger { display: flex !important; }
    .desktop-nav { display: none !important; }
    .brand-logo { height: 30px; }
    .brand-text { font-size: 1rem; }

    /* Body: reset padding-top for mobile navbar height */
    body { padding-top: 56px; }

    /* Auth form — center vertically with breathing room */
    .auth-container {
        align-items: center;
        padding: 20px 16px;
        min-height: calc(100vh - 56px);
    }
    .auth-box {
        padding: 28px 20px;
        border-radius: 16px;
        max-width: 100%;
    }

    /* Hero Responsive */
    .hero {
        padding-top: 50px;
        padding-bottom: 50px;
    }
    .hero h1 { font-size: 2.2rem; }
    .hero p { font-size: 1rem; }
    .hero-actions { flex-direction: column; gap: 10px; }
    .hero-actions .btn { width: 100%; text-align: center; }

    /* Section Typography */
    .section-title { font-size: 1.8rem; }
    .section-padding { padding: 60px 0; }

    /* Grids */
    .grid-2 { grid-template-columns: 1fr; }
    .gallery-grid { grid-template-columns: 1fr; }
}

/* (old mobile menu code removed — now using drawer system above) */




/* --- Premium Enhancements --- */
:root {
    --gradient-start: #0066cc;
    --gradient-end: #00c6ff;
}

.bg-shape {
    position: absolute;
    top: -10%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0, 102, 204, 0.08) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    z-index: -1;
}

.text-gradient {
    background: linear-gradient(90deg, var(--gradient-start), var(--gradient-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem !important;
    line-height: 1.6;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gradient-start), var(--primary-color)) !important;
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.3) !important;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 102, 204, 0.4) !important;
}

.btn-link:hover {
    transform: translateX(5px);
}
.btn-link span {
    display: inline-block;
    transition: transform 0.3s ease;
}
.btn-link:hover span {
    transform: translateX(4px);
}

.features-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: -30px;
    padding-bottom: 80px;
}

.feature-card {
    background-color: #ffffff;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0,0,0,0.02);
    position: relative;
    z-index: 1;
}

.feature-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 102, 204, 0.08);
    border-color: rgba(0, 102, 204, 0.1);
    z-index: 2;
}

.feature-icon {
    width: 64px;
    height: 64px;
    color: var(--primary-color);
    margin: 0 auto 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 102, 204, 0.1);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.feature-icon svg {
    width: 32px;
    height: 32px;
}

.feature-card:hover .feature-icon {
    background: var(--primary-color);
    color: white;
    transform: rotateY(180deg);
}

.feature-title {
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    margin-bottom: 15px !important;
}

.feature-desc {
    color: var(--text-muted) !important;
    font-size: 0.95rem !important;
    line-height: 1.6 !important;
}

/* Hide old feature boxes to avoid conflict */
.features { display: none; }
