/* CHARTER EXPRESS VOYAGES - app stylesheet
   Brand color CSS variables (--primary-color etc.) are injected by
   layouts/main.blade.php in a small inline <style> block, since their
   values come from BrandHelper (PHP) rather than being static here. */

* {
    font-family: 'Inter', sans-serif;
}

body {
    color: #333;
    background-color: #fff;
}

/* Navbar */
.navbar {
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-brand {
    color: var(--primary-color);
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.navbar-brand img {
    height: 52px;
    width: auto;
}

.nav-link {
    color: #555;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: color 0.3s;
}

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

.mobile-menu-btn {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--primary-color);
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}

.mobile-nav {
    display: none;
    flex-direction: column;
    background: white;
    border-top: 1px solid #eee;
    padding: 8px 20px 20px;
}

.mobile-nav.open {
    display: flex;
}

.mobile-nav .nav-link {
    padding: 12px 0;
    border-bottom: 1px solid #f3f3f3;
    font-size: 15px;
}

.mobile-nav-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
}

/* Buttons */
.primary-btn {
    background-color: var(--accent-color);
    color: white;
    padding: 10px 24px;
    border-radius: 6px;
    text-decoration: none;
    display: inline-block;
    font-weight: 600;
    font-size: 14px;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
}

.primary-btn:hover {
    background-color: #c0392b;
}

.secondary-btn {
    background-color: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 8px 22px;
    border-radius: 6px;
    text-decoration: none;
    display: inline-block;
    font-weight: 600;
    transition: all 0.3s;
}

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

/* Section titles */
.section-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 30px;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--accent-color);
}

/* Generic card */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* Hero */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 80px 20px;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    pointer-events: none;
}

.search-form {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    margin-top: -40px;
    position: relative;
    z-index: 10;
}

/* Forms */
.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 8px;
    font-size: 14px;
}

.form-input,
.form-select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 5px rgba(5, 34, 72, 0.2);
}

/* Footer */
footer {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-top: 3px solid var(--gold-color);
    color: white;
    padding: 50px 20px 20px;
    margin-top: 60px;
}

footer a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

footer a:hover {
    color: white;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

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

.badge-danger {
    background-color: #f8d7da;
    color: #721c24;
}

.badge-gold {
    background-color: var(--gold-color);
    color: var(--primary-color);
}

.rating {
    color: #ffc107;
    font-size: 14px;
}

/* Route / travel & bus cards */
.route-card {
    background: white;
    border: 1px solid #e8e8ec;
    border-radius: 12px;
    padding: 22px;
    transition: box-shadow 0.25s, transform 0.25s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.route-card:hover {
    box-shadow: 0 10px 24px rgba(5, 34, 72, 0.1);
    transform: translateY(-3px);
}

.route-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 17px;
    color: #111;
    margin-bottom: 6px;
    flex-wrap: wrap;
    word-break: break-word;
}

.route-card-header i {
    color: var(--secondary-color);
    font-size: 16px;
}

.route-meta {
    font-size: 13px;
    color: #8a8f98;
    margin-bottom: 18px;
}

.route-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding-top: 14px;
    border-top: 1px solid #f1f1f3;
    margin-bottom: 16px;
    flex: 1;
    gap: 10px;
    flex-wrap: wrap;
}

.route-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #9a9fa8;
    text-transform: uppercase;
    margin-bottom: 3px;
}

.route-date {
    font-size: 13px;
    color: #555;
    font-weight: 500;
}

.route-price {
    font-size: 21px;
    font-weight: 700;
    color: var(--secondary-color);
}

.route-book-btn {
    display: block;
    text-align: center;
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    background: var(--accent-color);
    color: white;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: background 0.25s;
}

.route-book-btn:hover {
    background: #c0392b;
}

.route-book-btn.disabled {
    background: #cbd0d6;
    color: #6b7280;
    cursor: not-allowed;
    pointer-events: none;
}

/* Compact variant: denser grids (e.g. 4-up popular routes) need smaller type */
.route-card-compact {
    padding: 16px;
}

.route-card-compact .route-card-header {
    font-size: 14px;
    gap: 5px;
}

.route-card-compact .route-card-header i {
    font-size: 13px;
}

.route-card-compact .route-meta {
    font-size: 11px;
    margin-bottom: 10px;
}

.route-card-compact .route-price {
    font-size: 17px;
}

/* Agency contact directory cards */
.agency-directory-card {
    background: white;
    border: 1px solid #e8e8ec;
    border-radius: 14px;
    padding: 20px;
    transition: box-shadow 0.25s, transform 0.25s;
}

.agency-directory-card:hover {
    box-shadow: 0 10px 24px rgba(5, 34, 72, 0.08);
    transform: translateY(-2px);
}

.agency-directory-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.agency-directory-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: rgba(0, 80, 160, 0.12);
    color: var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.agency-directory-name {
    font-weight: 700;
    font-size: 15px;
    color: #111;
    line-height: 1.2;
    word-break: break-word;
}

.agency-directory-label {
    font-size: 11px;
    color: #9a9fa8;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
}

.agency-directory-route {
    font-size: 13px;
    color: #555;
    font-weight: 600;
    margin-bottom: 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid #f1f1f3;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.agency-directory-route i {
    color: var(--accent-color);
    font-size: 14px;
}

.agency-directory-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.agency-directory-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.agency-directory-row-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(5, 34, 72, 0.08);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex-shrink: 0;
}

.agency-directory-row-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9a9fa8;
    margin-bottom: 2px;
}

.agency-directory-row a {
    font-size: 14px;
    color: #333;
    font-weight: 600;
    text-decoration: none;
}

.agency-directory-row a:hover {
    color: var(--secondary-color);
}

/* Language switcher */
.lang-switcher {
    display: flex;
    gap: 8px;
    align-items: center;
}

.lang-link {
    padding: 4px 12px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

.lang-link.active {
    background-color: var(--primary-color);
    color: white;
}

.lang-link:not(.active) {
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

/* Feature cards (e.g. "Why choose us") */
.feature-card {
    background: white;
    border: 1px solid #e8e8ec;
    border-radius: 14px;
    padding: 24px;
    text-align: left;
    transition: box-shadow 0.25s, transform 0.25s;
    height: 100%;
}

.feature-card:hover {
    box-shadow: 0 10px 24px rgba(5, 34, 72, 0.08);
    transform: translateY(-2px);
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(0, 80, 160, 0.1);
    color: var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 16px;
}

.feature-title {
    font-weight: 700;
    font-size: 16px;
    color: #111;
    margin-bottom: 6px;
}

.feature-desc {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
}

/* Testimonials */
.eyebrow-label {
    display: block;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.testimonial-card {
    background: white;
    border: 1px solid #e8e8ec;
    border-radius: 14px;
    padding: 26px;
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.25s, transform 0.25s;
}

.testimonial-card:hover {
    box-shadow: 0 10px 24px rgba(5, 34, 72, 0.08);
    transform: translateY(-2px);
}

.testimonial-stars {
    color: var(--gold-color);
    font-size: 14px;
    margin-bottom: 14px;
}

.testimonial-quote {
    font-style: italic;
    color: #4b5563;
    font-size: 14.5px;
    line-height: 1.6;
    margin-bottom: 20px;
    flex: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.testimonial-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

.testimonial-name {
    font-weight: 700;
    font-size: 14px;
    color: #111;
}

.testimonial-role {
    font-size: 13px;
    color: #8a8f98;
}

/* Payment method picker */
.payment-option {
    display: block;
    cursor: pointer;
}

.payment-option-input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.payment-option-card {
    display: block;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    padding: 10px 12px;
    transition: border-color 0.2s, background 0.2s;
}

.payment-option-input:checked + .payment-option-card {
    border-color: var(--secondary-color);
    background: rgba(0, 80, 160, 0.06);
}

.payment-option-label {
    display: block;
    font-weight: 700;
    font-size: 13px;
    color: #111;
}

.payment-option-number {
    display: block;
    font-size: 11px;
    color: #6b7280;
    margin-top: 4px;
}

.payment-option-pending {
    color: #b45309;
    font-style: italic;
}

/* Toast notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 360px;
}

.toast {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: white;
    border-left: 4px solid var(--secondary-color);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    padding: 14px 16px;
    font-size: 14px;
    color: #333;
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.25s, transform 0.25s;
}

.toast-show {
    opacity: 1;
    transform: translateX(0);
}

.toast i {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 1px;
}

.toast-success {
    border-left-color: #16a34a;
}

.toast-success i {
    color: #16a34a;
}

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

.toast-error i {
    color: var(--accent-color);
}

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

@media (max-width: 500px) {
    .toast-container {
        left: 16px;
        right: 16px;
        max-width: none;
    }
}

/* Loading spinner inside a button, while an AJAX call is in flight —
   swap a button's default/loading <span> pair via .hidden so a slow
   response (real SMTP send, gateway call) never looks like a stuck click. */
.btn-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    vertical-align: middle;
    animation: gp-btn-spin 0.7s linear infinite;
}

@keyframes gp-btn-spin {
    to { transform: rotate(360deg); }
}

.btn-spinner-dark {
    border-color: rgba(0, 0, 0, 0.15);
    border-top-color: var(--secondary-color);
}

/* Page loader */
.page-loader {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.page-loader-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.page-loader-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
}

.page-loader-spinner {
    width: 44px;
    height: 44px;
    border: 4px solid #e5e7eb;
    border-top-color: var(--secondary-color);
    border-radius: 50%;
    animation: page-loader-spin 0.8s linear infinite;
}

@keyframes page-loader-spin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    .page-loader-spinner {
        animation: none;
    }
}

/* Responsive adjustments */
@media (max-width: 767px) {
    .section-title {
        font-size: 24px;
    }

    .hero-section {
        padding: 50px 16px;
    }

    .route-price {
        font-size: 18px;
    }

    .navbar-brand img {
        height: 40px;
    }
}

@media (max-width: 400px) {
    .route-footer {
        flex-direction: column;
        align-items: flex-start;
    }
}
