/* Global Styles */
html, body {
    margin: 0;
    padding: 0;
    font-family: 'Arial', sans-serif;
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

h1, h2 {
    color: #0fd23c;
    text-shadow: 2px 3px 3px rgba(1, 1, 1, 0.632);
    font-weight: bold;
    text-align: center;
}

main {
    flex: 1 0 auto;
    position: relative;
}

/* Removed global background images to standardize hero-based design */

/* Booking Button Styles */
#desktop-booking-btn {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.75rem;
    padding: 15px 30px;
    background: linear-gradient(90deg, #28a745, #218838);
    color: white;
    border: none;
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    z-index: 1050;
    transition: all 0.3s ease;
    animation: glowing 3s infinite ease-in-out;
}

#desktop-booking-btn:hover {
    background: linear-gradient(90deg, #218838, #28a745);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    transform: translate(-50%, -50%) scale(1.05);
}

@keyframes glowing {
    0%, 100% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    }
    50% {
        box-shadow: 0 4px 30px rgba(172, 243, 8, 0.8);
    }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: #fff;
    padding: 20px;
    width: 80vw;
    height: 80vh;
    max-width: 1100px;
    max-height: 90vh;
    min-width: 300px;
    min-height: 400px;
    border-radius: 10px;
    position: relative;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.modal-fade-in {
    animation: fadeIn 0.3s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.close {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #000;
    cursor: pointer;
    transition: transform 0.2s ease, color 0.3s ease;
}

.close:hover {
    color: red;
    transform: scale(1.4);
}

/* Tinted Overlay */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Adjust opacity as needed */
    z-index: -1; /* Behind all main content */
}

/* Footer Styling */
footer {
    background-color: #343a40;
    padding: 10px 0;
    color: white;
    text-align: center;
    width: 100%;
    margin-top: auto;
}

footer p {
    margin: 0;
}

/* Contact/Complaint Form Styling */
form div {
    margin-bottom: 1.5rem;
}

form label {
    font-weight: bold;
    color: #333;
    display: block;
    margin-bottom: 0.5rem;
}

form input, form textarea, form select {
    width: 100%;
    padding: 0.75rem;
    border-radius: 5px;
    border: 1px solid #ccc;
}

form textarea {
    resize: vertical;
}

form button[type="submit"] {
    background-color: #28a745;
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

form button[type="submit"]:hover {
    background-color: #218838;
}

.form-container {
    background-color: #ffffff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin: 20px auto;
    max-width: 700px;
}

/* Removed legacy .card styling for old Services layout */

/* Success Modal Styles */
#successModal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
}

#successModal .modal-content {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    width: 80%;
    max-width: 400px;
    position: relative;
}

#successModal .close {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
}

/* Default email font styling */
.contact-email {
    font-size: 1.5rem; /* Larger default size */
    font-weight: bold;
    color: #0fd23c; /* Matches your brand color */
    text-decoration: none;
}

/* Hover effect */
.contact-email:hover {
    text-decoration: underline; /* Underline on hover for accessibility */
}

/* Responsive font adjustments */
@media (max-width: 768px) {
    .contact-email {
        font-size: 1.25rem; /* Slightly smaller on smaller screens */
    }
}

@media (max-width: 480px) {
    .contact-email {
        font-size: 1rem; /* Smaller size for very small screens */
    }
}


/* Contact Page Content Styling */
.contact-page-content {
    z-index: 1; /* Ensures content is above the overlay */
    position: relative;
    padding: 20px;
}

/* Map Card Styling */
.map-card {
    background-color: rgba(4, 4, 4, 0.0);
    border-radius: 8px;
    padding: 1.5rem;
    max-width: 700px;
    margin: 0 auto;
}

.map-container {
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* ---- Modern Services Page Additions ---- */
:root {
    --brand-black: #0b0b0b;
    --brand-yellow: #f5c518; /* taxi yellow */
    --brand-yellow-strong: #e5b400;
    --brand-green: #16a34a;
    --bg: #ffffff;
    --text: #0f172a;
    --muted: #475569;
    --card: #ffffff;
    --border: #e5e7eb;
    --radius: 14px;
    --shadow: 0 8px 30px rgba(2, 6, 23, 0.08);
}

/* Make the Services page background clean and readable */
.our-services-page {
    background: var(--bg);
    background-image: none !important;
    color: var(--text);
}
.our-services-page .navbar { background-color: var(--brand-black) !important; }
.our-services-page .nav-link { color: #f8fafc !important; }
.our-services-page .nav-link:hover { color: var(--brand-yellow) !important; }

.our-services-page .hero {
    background: linear-gradient(180deg, rgba(11, 11, 11, 0.84), rgba(11,11,11,0.9)), url('images/Prom-coast-taxi.jpg') center/cover no-repeat;
    color: #fff;
    padding: 72px 16px;
    text-align: center;
}
.our-services-page .hero h1 {
    color: #fff;
    font-size: clamp(2rem, 2.8vw + 1rem, 3rem);
    margin: 0 0 12px;
}
.our-services-page .hero p {
    color: #e5e7eb;
    max-width: 60ch;
    margin: 0 auto 20px;
}
.btn-accent {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--brand-yellow);
    color: #000;
    border: none;
    border-radius: 999px;
    padding: 12px 18px;
    font-weight: 700;
    box-shadow: 0 6px 20px rgba(245, 197, 24, 0.35);
    transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn-accent:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(245,197,24,.5); background: var(--brand-yellow-strong); text-decoration: none; color:#000; }
.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 2px solid #fff;
    color: #fff;
    border-radius: 999px;
    padding: 10px 16px;
    font-weight: 700;
    transition: background .2s ease, color .2s ease;
}
.btn-outline:hover { background: #fff; color: #000; text-decoration: none; }

.our-services-page .section { padding: 56px 16px; }
.our-services-page .section h2 { color: var(--text); text-align: left; margin-bottom: 12px; }
.our-services-page .section p.lead { color: var(--muted); margin-bottom: 24px; }

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}
.service-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px;
    box-shadow: var(--shadow);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.service-card:hover { transform: translateY(-4px); box-shadow: 0 12px 36px rgba(2,6,23,.12); border-color: #d1d5db; }
.service-card .icon { width: 44px; height: 44px; color: var(--brand-yellow); margin-bottom: 8px; }
.service-card h3 { margin: 6px 0 6px; font-size: 1.1rem; color: var(--text); font-weight: 800; }
.service-card p { margin: 0; color: var(--muted); }
.service-card .badge-row { display:flex; gap:8px; margin-top:10px; flex-wrap:wrap; }
.badge { font-size: .8rem; padding: .25rem .5rem; border-radius: 999px; background:#eef2f7; color:#334155; }
.badge.accent { background: rgba(245,197,24,.16); color:#7c5e00; }

.reveal { opacity: 0; transform: translateY(12px); transition: opacity .4s ease, transform .4s ease; }
.reveal.in { opacity: 1; transform: none; }

.sticky-cta { position: fixed; right: 16px; bottom: 16px; z-index: 1050; }
@media (min-width: 992px) { .sticky-cta { display: none; } }

.cta-strip { background: #111827; color: #fff; padding: 28px 16px; text-align: center; }
.cta-strip .btn-accent { margin-left: 10px; }

/* Mobile Call button */
.btn-call {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--brand-green);
    color: #fff !important;
    border: none;
    border-radius: 999px;
    padding: 12px 18px;
    font-weight: 700;
    box-shadow: 0 6px 20px rgba(22, 163, 74, 0.35);
    transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn-call:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(22,163,74,.5); text-decoration: none; }
.sticky-call { position: fixed; right: 16px; bottom: 72px; z-index: 1050; }
@media (min-width: 992px) { .sticky-call { display: none; } }

/* Reviews section */

/* Collapsible wrapper to limit 3rd-party widget height */
.reviews-collapsible { max-height: 640px; overflow: hidden; position: relative; }
.reviews-collapsible.collapsed::after {
    content: "";
    position: absolute; left: 0; right: 0; bottom: 0; height: 80px;
    background: linear-gradient(to bottom, rgba(255,255,255,0), var(--bg));
    pointer-events: none;
}
.reviews-collapsible.expanded { max-height: none; }
.reviews-toggle { margin-top: 12px; }

/* Navbar ticker (desktop) */
.navbar { position: relative; }
.nav-ticker { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: none; }
@media (min-width: 992px) { .nav-ticker { display: block; } }
.nav-ticker .ticker-track { position: relative; min-width: 320px; height: 28px; }
.nav-ticker .ticker-item { position: absolute; left: 0; right: 0; opacity: 0; transform: translateY(6px); transition: opacity .3s ease, transform .3s ease; text-align: center; color: #f8fafc; font-weight: 700; }
.nav-ticker .ticker-item.in { opacity: 1; transform: none; }
.nav-ticker .chip { background: rgba(255,255,255,.12); color: #f8fafc; border-radius: 999px; padding: 4px 10px; display: inline-flex; align-items: center; gap: 8px; }
.nav-ticker .chip-accent { background: rgba(245,197,24,.18); color: #fff; }
.link-plain { color: inherit; text-decoration: none; }
.link-plain:hover { text-decoration: underline; }

/* Home hero */
.hero {
    background: linear-gradient(180deg, rgba(11,11,11,0.84), rgba(11,11,11,0.9)), url('images/Prom-coast-taxi.jpg') center/cover no-repeat;
    color: #fff;
    padding: 72px 16px;
    text-align: center;
}
.hero h1 { color:#fff; font-size: clamp(2rem, 2.8vw + 1rem, 3rem); margin: 0 0 12px; font-weight: 800; }
.hero p { color:#e5e7eb; margin:0 0 20px; }
.cta-row { display:flex; gap:12px; justify-content:center; flex-wrap:wrap; }

/* Consistent navbar sizing across pages */
.navbar { padding: 12px 16px; min-height: 68px; }
.navbar .nav-link { padding: 0.5rem 0.75rem; }
.navbar-brand img { height: 44px; width: auto; display: block; }
@media (max-width: 991.98px) {
  .navbar { padding: 8px 12px; min-height: 56px; }
  .navbar-brand img { height: 36px; }
}

/* Ensure uniform navbar on all pages (strong specificity) */
.navbar.navbar-dark.bg-dark { padding: 12px 16px !important; min-height: 68px !important; }
.navbar.navbar-dark.bg-dark .navbar-brand img { height: 44px !important; width: auto !important; display: block; }
.navbar.navbar-dark.bg-dark .nav-link { padding: 0.5rem 0.75rem !important; }

/* Mobile navbar: full-screen dark backdrop for readability */
@media (max-width: 991.98px) {
  .navbar { z-index: 1300; }
  .mobile-nav-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.5);
    opacity: 0; visibility: hidden; transition: opacity .2s ease;
    z-index: 1200;
  }
  body.nav-open .mobile-nav-overlay { opacity: 1; visibility: visible; }

  .navbar-collapse {
    position: fixed; top: 0; right: 0; height: 100%; width: 82vw; max-width: 360px;
    background: #0b0b0b; padding: 72px 16px 16px; box-shadow: -8px 0 20px rgba(0,0,0,0.3);
    transform: translateX(100%); transition: transform .25s ease; z-index: 1210;
  }
  .navbar-collapse.show { transform: translateX(0); }
  .navbar-collapse .nav-link { color: #ffffff !important; font-size: 1.05rem; padding: 12px 8px; }
  .navbar-collapse .nav-item { margin-bottom: 8px; }
  .nav-close { position: absolute; top: 16px; right: 16px; background: transparent; border: 0; color: #fff; font-size: 1.75rem; line-height: 1; }
}

/* Booking loader overlay (mobile) */
#taxicaller-booking-form { position: relative; }
.loading-overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 10px; background: rgba(17,17,17,0.35); color: #fff; z-index: 0; pointer-events: none; }
.spinner { width: 32px; height: 32px; border: 3px solid rgba(245,197,24,0.32); border-top-color: var(--brand-yellow); border-radius: 50%; animation: spin 0.8s linear infinite; }
.loading-text { font-size: 0.95rem; color: #f3f4f6; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Passive spinner while booking form is empty (no JS needed) */
@media (max-width: 991.98px) {
  /* Ensure the container has height while empty so the spinner is visible */
  .index-page #taxicaller-booking-form:empty { min-height: 200px; }
  .index-page #taxicaller-booking-form:empty::before,
  .index-page #taxicaller-booking-form.loading::before {
    content: '';
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    width: 100%; height: 100%;
    background: rgba(17,17,17,0.25);
    pointer-events: none;
    z-index: 0;
  }
  .index-page #taxicaller-booking-form:empty::after,
  .index-page #taxicaller-booking-form.loading::after {
    content: '';
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 32px; height: 32px; border: 3px solid rgba(245,197,24,0.32); border-top-color: var(--brand-yellow); border-radius: 50%;
    animation: spin 0.8s linear infinite;
    pointer-events: none;
    z-index: 0;
  }
}
@media (min-width: 992px) {
  .index-page #taxicaller-booking-form:empty::before,
  .index-page #taxicaller-booking-form:empty::after {
    content: none !important;
    display: none !important;
  }
}

/* Ensure booking content behaves per widget defaults (no forced stacking) */

/* Index page overrides: hide legacy centered button and reset positioning */
.index-page #desktop-booking-btn { display: none !important; position: static; transform: none; top: auto; left: auto; }

/* Index sections: align spacing with Services, add light panel */
.index-page .section { padding: 56px 16px; }
.section--light { background: var(--bg); }
.index-page .desktop-only { display: block; }
@media (max-width: 991.98px) { .index-page .desktop-only { display: none; } }

/* Generic section typography (used by index + services) */
.section h2 { color: var(--text); text-align: center; margin-bottom: 12px; font-weight: 800; }
.section p.lead { color: var(--muted); margin-bottom: 24px; }

/* Inquiry status badge (Contact form) */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
    background: #eef2f7;
    color: #334155;
    margin-top: 6px;
}
.status-badge.status-complaint { background: rgba(245,197,24,.16); color: #7c5e00; }
.status-badge.status-general { background: rgba(22,163,74,.14); color: #065f46; }

/* Modern form styles */
.form-grid { display: grid; gap: 16px; }
@media (min-width: 768px) { .form-grid { grid-template-columns: 1fr 1fr; } }
.field { position: relative; margin-bottom: 16px; }
.field.floating input,
.field.floating textarea { padding-top: 1.25rem; }
.field.floating label {
  position: absolute; left: 12px; top: 10px; color: #6b7280; pointer-events: none;
  transition: transform .15s ease, color .15s ease, top .15s ease, font-size .15s ease;
}
.field.floating input::placeholder,
.field.floating textarea::placeholder { color: transparent; }
.field.floating input:focus + label,
.field.floating input:not(:placeholder-shown) + label,
.field.floating textarea:focus + label,
.field.floating textarea:not(:placeholder-shown) + label {
  top: 4px; font-size: .75rem; color: #374151;
}
.field .counter { position: absolute; right: 8px; bottom: 8px; font-size: .8rem; color: #6b7280; }
.field input:focus, .field textarea:focus, select:focus { outline: 2px solid var(--brand-yellow); outline-offset: 2px; }
.complaint-panel { border: 1px solid var(--border); border-radius: 10px; padding: 12px; background: #fff; margin-top: 8px; }
.complaint-panel-title { font-weight: 700; color: var(--text); margin-bottom: 6px; font-size: .95rem; }
.help-text { font-size: .9rem; color: #6b7280; margin-top: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,1,1); white-space: nowrap; border: 0; }

/* Towns we serve list */
.towns-list { list-style: none; padding: 0; margin: 16px auto 0; max-width: 900px; }
.towns-list li { color: var(--text); padding: 6px 0; border-bottom: 1px solid var(--border); }
.towns-list li:last-child { border-bottom: 0; }
@media (min-width: 768px) {
  .towns-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 8px 24px; }
  .towns-list li { border-bottom: 0; padding: 4px 0; }
}

/* Modern site footer */
.site-footer { background:#0b0b0b; color:#e5e7eb; padding: 40px 0 24px; }
.site-footer a { color:#e5e7eb; text-decoration: none; }
.site-footer a:hover { color: var(--brand-yellow); text-decoration: underline; }
.site-footer h4 { color:#fff; font-weight:800; font-size:1.05rem; margin-bottom:.75rem; }
.footer-grid { display:grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.footer-brand .small { color:#cbd5e1; margin-top:.25rem; }
.footer-hours { color:#cbd5e1; font-size:.9rem; margin-top:.5rem; }
.footer-hours .sep { margin: 0 .4rem; color:#94a3b8; }
.footer-social { margin-top:.5rem; display:flex; gap:10px; }
.footer-social a { display:inline-flex; align-items:center; justify-content:center; width:34px; height:34px; border-radius:999px; background: rgba(255,255,255,.08); }
.footer-social a:hover { background: rgba(245,197,24,.18); }
.footer-bottom { border-top:1px solid rgba(255,255,255,.08); margin-top:20px; padding-top:14px; text-align:center; color:#cbd5e1; font-size:.95rem; }

/* Fare estimator */
#fare-estimator .form-grid { align-items: end; }
#fareResult .badge { background:#eef2f7; }
/* Estimator loading overlay */
#fare-estimator { position: relative; }
#fare-estimator .loading-overlay { position:absolute; inset:0; display:none; align-items:center; justify-content:center; flex-direction:column; gap:10px; background: rgba(17,17,17,0.35); color:#fff; z-index: 5; }
#fare-estimator .spinner { width: 36px; height: 36px; border: 3px solid rgba(245,197,24,0.32); border-top-color: var(--brand-yellow); border-radius: 50%; animation: spin 0.8s linear infinite; }
#fare-estimator .loading-text { font-size: 0.95rem; color: #f3f4f6; }
#fare-estimator.estimating .loading-overlay { display:flex; }

/* Autocomplete dropdown */
.field { position: relative; }
.ac-list { position:absolute; left:0; right:0; top:100%; margin-top:6px; background:#fff; border:1px solid var(--border); border-radius:12px; box-shadow: 0 8px 30px rgba(2,6,23,.12); list-style:none; padding:6px 0; z-index:20; max-height: 280px; overflow:auto; display:none; }
.ac-item { padding:10px 14px; cursor:pointer; color:var(--text); line-height:1.2; }
.ac-item small { color: #6b7280; display:block; margin-top:2px; }
.ac-item:hover { background:#f8fafc; }
.ac-item.active { background: rgba(245,197,24,.16); }
.ac-list.show { display:block; }

/* Index page background: no fixed background image */
.index-page {
    background: var(--bg);
    background-image: none !important;
    color: var(--text);
}

/* Mobile on-demand fullscreen booking */
@media (max-width: 991.98px) {
  body.booking-fullscreen-open {
    overflow: hidden;
  }
  body.booking-fullscreen-open #taxicaller-booking-form {
    position: fixed; inset: 0; z-index: 1400; padding: 0 !important; margin: 0 !important; background: #000;
  }
  body.booking-fullscreen-open #taxicaller-booking-form > *,
  body.booking-fullscreen-open #taxicaller-booking-form iframe {
    width: 100vw !important; height: 100vh !important; max-height: 100vh !important; display: block !important;
  }
  .booking-exit {
    position: fixed; right: 12px; top: 12px; z-index: 1500; background: #fff; color: #000; border: 0; border-radius: 999px; padding: 8px 12px; font-weight: 700; box-shadow: 0 8px 20px rgba(0,0,0,.25);
  }
}

/* (Reverted) Let the booking widget control its own height on mobile */

/* Unify navbar style across pages */
.navbar.navbar-dark.bg-dark { background-color: #0b0b0b !important; }
.navbar.navbar-dark .nav-link { color: #f8fafc !important; }
.navbar.navbar-dark .nav-link:hover { color: var(--brand-yellow) !important; }
