/* Modern Expo Tech Design - Navy & Red Aesthetic */
:root {
    /* Colors */
    --bg-primary: #FFFFFF;
    --bg-secondary: #F8FAFC;
    /* Very light slate */
    --bg-tertiary: #F1F5F9;
    /* Light slate */

    --text-primary: #0F172A;
    /* Dark Navy/Slate */
    --text-secondary: #475569;
    /* Slate Grey */
    --text-tertiary: #94A3B8;
    /* Light Grey */

    /* Brand Colors */
    --brand-navy: #0B1C3E;
    --brand-red: #D94025;

    --accent-primary: #D94025;
    /* Logo Red */
    --accent-hover: #B91C1C;
    --accent-light: #FEF2F2;

    --accent-secondary: #0B1C3E;
    /* Logo Navy */

    --border-color: #E2E8F0;

    --success: #10B981;
    --error: #EF4444;
    --warning: #F59E0B;

    /* Typography */
    --font-heading: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    /* Spacing */
    --container-max: 1200px;
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;

    /* Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    /* Transitions */
    --transition: all 0.2s ease-in-out;
}

/* Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    background-image: url('/static/images/bg.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* Accessibility - Skip to content link */
.skip-to-content {
    position: absolute !important;
    left: -9999px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    z-index: 999;
    padding: 1rem 1.5rem;
    background-color: var(--brand-navy);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
}

.skip-to-content:focus {
    position: absolute !important;
    left: 1rem !important;
    top: 1rem !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
}

/* Layout */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

.main-content {
    flex: 1;
    padding: var(--spacing-md) 0;
    min-height: calc(100vh - 400px);
}

/* Breadcrumbs */
.breadcrumbs {
    background: var(--bg-secondary);
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.breadcrumbs .container,
.breadcrumbs > * {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.breadcrumb-item {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.breadcrumb-item:hover {
    color: var(--accent-primary);
}

.breadcrumb-item.active {
    color: var(--text-primary);
    font-weight: 500;
}

.breadcrumb-separator {
    margin: 0 0.5rem;
    color: var(--text-tertiary);
}

/* Navbar */
.navbar {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo {
    height: 48px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link:hover,
.nav-link.active {
    color: var(--brand-navy);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--brand-red);
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
}

/* Cart Badge */
.cart-badge {
    background: var(--brand-red);
    color: white;
    font-size: 0.75rem;
    padding: 0.15rem 0.4rem;
    border-radius: var(--radius-full);
    margin-left: 0.25rem;
}

/* Language Toggle Button */
.language-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 1rem;
    border: 2px solid rgba(102, 126, 234, 0.2);
    border-radius: 50px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.language-toggle-btn:hover {
    border-color: rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.1);
}

.lang-option {
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.lang-option.active {
    color: var(--brand-navy);
    font-weight: 700;
}

.lang-divider {
    color: var(--border-color);
    font-weight: 300;
}

/* Buttons */
.btn-primary {
    display: inline-block;
    background: var(--brand-navy);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    width: auto;
}

.btn-primary:hover {
    background: #1e293b;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

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

/* Cards */
.card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    margin-bottom: 1.5rem;
}

.card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
    border-color: var(--accent-light);
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--brand-navy);
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.page-title {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: #FFFFFF;
}

.page-subtitle {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.1rem;
}

/* Section Headers - Better visibility on background */
.container h2 {
    color: white !important;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.container h2 + p {
    color: white !important;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
}

/* Forms */
.form-box {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    max-width: 500px;
    width: 100%;
    margin: 0 auto;
    border: 1px solid var(--border-color);
}

.input-group {
    margin-bottom: 1.5rem;
    width: 100%;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
}

.form-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 16px;
    transition: var(--transition);
}

.form-input:focus {
    outline: none;
    border-color: var(--brand-navy);
    box-shadow: 0 0 0 3px rgba(11, 28, 62, 0.1);
}

/* Prevent Safari auto-zoom on input fields */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="url"],
input[type="search"],
input[type="date"],
input[type="time"],
input[type="datetime-local"],
input[type="file"],
select,
textarea {
    font-size: 16px;
}

/* Footer */
.footer {
    background: var(--brand-navy);
    color: white;
    padding: 4rem 0 2rem;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-col h3 {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--brand-red);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--text-tertiary);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.data-table th,
.data-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.data-table th {
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-secondary);
}

.data-table td {
    color: var(--text-primary);
}

/* Badges */
.badge {
    display: inline-flex;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 500;
}

.badge-info {
    background: #E0F2FE;
    color: #0369A1;
}

.badge-success {
    background: #DCFCE7;
    color: #15803D;
}

.badge-warning {
    background: #FEF3C7;
    color: #B45309;
}

/* Payment Options & Grid */
.services-grid,
.payment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.payment-option-card {
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    background: var(--bg-secondary);
    position: relative;
    display: block;
}

.payment-option-card:hover,
.payment-option-card.active {
    border-color: var(--accent-primary);
    background: var(--bg-tertiary);
}

.payment-option-card input[type="radio"] {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
        margin: 0 auto;
    }

    body {
        padding: 0;
        margin: 0;
    }

    .main-content {
        padding: 1rem 0;
    }

    .navbar-container {
        flex-wrap: wrap;
        padding: 0 1rem;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        padding: 1rem 0;
        gap: 0.5rem;
    }

    .nav-links.active {
        display: flex;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* Filter Tabs */
.filter-tabs {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.filter-tab {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    background: var(--bg-secondary);
    font-weight: 500;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    cursor: pointer;
    text-decoration: none;
}

.filter-tab:hover,
.filter-tab.active {
    background: var(--brand-navy);
    /* Adjusted for new theme */
    color: white;
    border-color: var(--brand-navy);
}

/* Hero Section */
.hero {
    background: transparent;
    color: white;
    padding: 4rem 0;
    margin-bottom: 4rem;
    position: relative;
    overflow: hidden;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3.5rem;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.hero-subtitle {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    max-width: 500px;
    line-height: 1.6;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-image-container {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
}

.hero-image {
    width: 100%;
    max-width: 500px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 4px solid rgba(255, 255, 255, 0.1);
    transform: rotate(2deg);
    transition: var(--transition);
}

.hero-image:hover {
    transform: rotate(0);
}

.btn-outline-white {
    display: inline-block;
    background: transparent;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    text-decoration: none;
    border: 2px solid white;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.btn-outline-white:hover {
    background: white;
    color: var(--brand-navy);
}

/* Feature Cards (Home) */
.feature-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    height: 320px;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--brand-red);
}

.feature-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.feature-card:hover .feature-bg {
    transform: scale(1.05);
}

.feature-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(11, 28, 62, 0.95), rgba(11, 28, 62, 0.6), transparent);
    padding: 2rem 1.5rem 1.5rem;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    height: 50%;
}

.feature-title {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.feature-link {
    display: inline-flex;
    align-items: center;
    color: var(--brand-red);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 5px;
}

.feature-link::after {
    content: '→';
    margin-left: 0.5rem;
    transition: transform 0.2s;
}

.feature-link:hover::after {
    transform: translateX(5px);
}

@media (max-width: 900px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero-subtitle {
        margin: 0 auto 2.5rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-image {
        max-width: 100%;
        transform: none;
    }
}

/* Alerts & Messages */
.messages-container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 1rem 2rem;
    position: fixed;
    top: 80px;
    /* Below navbar */
    right: 0;
    left: 0;
    z-index: 900;
    pointer-events: none;
    /* Allow clicking through container */
}

.alert {
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: auto;
    /* Re-enable pointer events for alerts */
    animation: slideIn 0.3s ease-out;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    border-left: 4px solid transparent;
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

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

.alert-info {
    background-color: #EFF6FF;
    color: #1E40AF;
    border-left-color: #3B82F6;
}

.alert-success {
    background-color: #F0FDF4;
    color: #166534;
    border-left-color: var(--success);
}

.alert-warning {
    background-color: #FFFBEB;
    color: #92400E;
    border-left-color: var(--warning);
}

.alert-error,
.alert-danger {
    background-color: #FEF2F2;
    color: #991B1B;
    border-left-color: var(--error);
}

/* Toast (Alternative to simple alert) */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    pointer-events: none;
}

.toast {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 300px;
    border-left: 4px solid var(--brand-navy);
    animation: slideInRight 0.3s ease-out;
    pointer-events: auto;
    transition: opacity 0.3s ease-out, transform 0.3s ease-out;
}

.toast-success {
    border-left-color: var(--success);
}

.toast-error {
    border-left-color: var(--error);
}

.toast-info {
    border-left-color: var(--brand-navy);
}

.toast-icon {
    font-size: 1.25rem;
}

.toast-close {
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.25rem;
    color: var(--text-tertiary);
    padding: 0.25rem;
}

.toast-close:hover {
    color: var(--text-primary);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Mobile responsive toast */
@media (max-width: 768px) {
    .toast-container {
        bottom: 1rem;
        right: 1rem;
        left: 1rem;
        max-width: calc(100% - 2rem);
    }

    .toast {
        min-width: 0;
        width: 100%;
        max-width: 100%;
    }
}

/* Form Helper Classes */
.input-label {
    /* Alias to form-label for compatibility */
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
}

.form-title {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    text-align: center;
    color: var(--brand-navy);
}

.required {
    color: var(--error);
}

/* Checkbox alignment */
input[type="checkbox"] {
    accent-color: var(--brand-navy);
    width: 1.1rem;
    height: 1.1rem;
    cursor: pointer;
}