:root {
    --primary-dark: #0a3b5e;
    --primary: #0a3b5e;
    --accent: #d8c4a0;
    --highlight: #e87722;
    --text: #475569;
    --light-bg: #F8FAFC;
    --white: #FFFFFF;
    --sand: #d8c4a0;
    --coastal-blue: #0a3b5e;
    --sunset-orange: #e87722;
    --shadow: 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);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--text);
    overflow-x: hidden;
}

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

/* Navigation */
.navbar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: transparent;
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 120px;
    padding: 10px 0;
}

.nav-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-img {
    height: 100px;
    width: auto;
    max-width: 375px;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

.nav-logo a:hover .logo-img {
    opacity: 0.8;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.nav-link {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    opacity: 0.9;
}

.nav-link:hover {
    color: var(--white);
    opacity: 1;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: none;
    border: none;
    cursor: pointer;
}

.nav-toggle span {
    width: 100%;
    height: 3px;
    background: var(--white);
    transition: all 0.3s ease;
    transform-origin: center;
}

.nav-toggle.active span:nth-child(1) {
    transform: translateY(8.5px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: translateY(-8.5px) rotate(-45deg);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    color: var(--white) !important;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

.btn-secondary:hover {
    background: #0891B2CC;
    transform: translateY(-2px);
}

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

.btn-white:hover {
    background: var(--light-bg);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white) !important;
}

.hero-download {
    color: var(--white);
    border-color: var(--white);
    background: rgba(255, 255, 255, 0.1);
}

.hero-download:hover {
    background: var(--white);
    color: var(--primary-dark) !important;
    border-color: var(--white);
}

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

.nav-cta {
    padding: 8px 20px;
}

.btn-portal {
    background: var(--highlight);
    color: var(--white) !important;
    padding: 10px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    border: 2px solid var(--highlight);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
    position: relative;
    animation: pulse-glow 2s ease-in-out infinite;
}

.btn-portal:hover {
    background: #EA580C;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.4);
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
    }
    50% {
        box-shadow: 0 4px 20px rgba(249, 115, 22, 0.5);
    }
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 70vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: linear-gradient(135deg, var(--coastal-blue) 0%, rgba(10, 59, 94, 0.9) 100%);
    padding-top: 140px;
    padding-bottom: 2rem;
}

.hero-bg {
    position: absolute;
    inset: 0;
    opacity: 0.1;
    background-image:
        repeating-linear-gradient(45deg, transparent, transparent 35px, rgba(255,255,255,.05) 35px, rgba(255,255,255,.05) 70px),
        repeating-linear-gradient(-45deg, transparent, transparent 35px, rgba(255,255,255,.03) 35px, rgba(255,255,255,.03) 70px);
}

.hero-content {
    position: relative;
    text-align: center;
    color: var(--white);
    max-width: 800px;
    margin: 0 auto;
    animation: fadeInUp 0.8s ease;
    padding: 1rem 2rem;
}

.emergency-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    color: var(--white);
    padding: 0.5rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    margin-bottom: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    margin-bottom: 0.75rem;
    opacity: 0.9;
}

.hero-location {
    font-size: clamp(0.9rem, 1.5vw, 1rem);
    margin-bottom: 1.75rem;
    opacity: 0.85;
    font-weight: 500;
}

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

/* Service Card Links */
.service-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: all 0.3s ease;
}

.service-card-link:hover {
    text-decoration: none;
    color: inherit;
}

.service-card-link:hover .service-card {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-card-link .btn {
    cursor: pointer;
}


/* Sections */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.1rem;
    color: var(--text);
}

/* Services */
.services {
    background: var(--light-bg);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeIn 0.6s ease forwards;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.service-card h3 {
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
    font-size: 1.75rem;
    font-weight: 600;
    border-bottom: 3px solid var(--primary);
    padding-bottom: 0.75rem;
}

.price-badge {
    display: inline-block;
    background: var(--primary);
    color: var(--white);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 1rem;
}

.guarantee-badge {
    display: inline-block;
    background: var(--accent);
    color: var(--white);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    margin-left: 0.5rem;
}

.service-card p {
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.service-features {
    list-style: none;
}

.service-features li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.service-features li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

/* Why Choose */
.why-choose {
    background: var(--light-bg);
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.benefit-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--primary);
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeIn 0.6s ease forwards;
}

.benefit-card:nth-child(1) { animation-delay: 0.1s; }
.benefit-card:nth-child(2) { animation-delay: 0.15s; }
.benefit-card:nth-child(3) { animation-delay: 0.2s; }
.benefit-card:nth-child(4) { animation-delay: 0.25s; }
.benefit-card:nth-child(5) { animation-delay: 0.3s; }
.benefit-card:nth-child(6) { animation-delay: 0.35s; }

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-left-color: var(--accent);
}

.benefit-card h4 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
    font-size: 1.5rem;
    font-weight: 600;
}

.benefit-card p {
    color: var(--text);
    line-height: 1.7;
    font-size: 1rem;
}

/* CTA Banner */
.cta-banner {
    background: linear-gradient(135deg, var(--coastal-blue) 0%, var(--sand) 100%);
    padding: 60px 0;
    position: relative;
    overflow: hidden;
}

.cta-content {
    position: relative;
    text-align: center;
    color: var(--white);
}

.cta-content h2 {
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    margin-bottom: 1rem;
}

.cta-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Contact */
.contact {
    background: var(--light-bg);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 3rem;
}

.contact-form {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 1.5rem;
}

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.contact-info {
    padding-left: 2rem;
}

.info-item {
    margin-bottom: 2rem;
}

.info-item h4 {
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.info-item p {
    color: var(--text);
    line-height: 1.7;
}

.info-item a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.info-item a:hover {
    color: var(--primary-dark);
}

.contact-primary {
    background: var(--light-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary);
}

.contact-number a,
.contact-email a {
    font-size: 1.25rem;
    font-weight: 600;
}

.phone-link {
    font-weight: 600;
}

.quick-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

/* Footer */
.footer {
    background: var(--primary-dark);
    color: var(--white);
    padding: 2rem 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.footer-links a {
    color: var(--white);
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Scroll animations trigger class */
.fade-in-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.fade-in-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-info {
        padding-left: 0;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: absolute;
        top: 120px;
        left: -100%;
        flex-direction: column;
        background: rgba(30, 64, 175, 0.98);
        width: 100%;
        padding: 2rem;
        box-shadow: var(--shadow);
        transition: left 0.3s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        margin: 0.75rem 0;
    }

    .nav-link {
        font-size: 1.125rem;
        padding: 0.75rem;
        display: block;
    }

    .phone-link {
        background: rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        text-align: center;
    }

    .nav-toggle {
        display: flex;
        width: 44px;
        height: 44px;
        padding: 12px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .hero-buttons .btn {
        width: 100%;
        max-width: 320px;
        padding: 16px 24px;
        font-size: 1rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .benefits-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .benefit-card {
        padding: 1.5rem;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .cta-buttons .btn {
        width: 100%;
        max-width: 300px;
        padding: 16px 24px;
    }

    .btn {
        min-height: 48px;
        line-height: 1.5;
    }

    .contact-primary {
        margin-bottom: 2rem;
        text-align: center;
    }

    .contact-number a {
        display: inline-block;
        padding: 12px 24px;
        background: var(--primary);
        color: var(--white) !important;
        border-radius: 8px;
        font-size: 1.5rem;
        margin-top: 0.5rem;
    }

    .quick-links .btn {
        padding: 14px 20px;
        font-size: 1rem;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-links {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .logo-img {
        height: 80px;
    }

    .emergency-badge {
        font-size: 0.9rem;
        padding: 0.4rem 1rem;
    }
}

@media (max-width: 480px) {
    section {
        padding: 60px 0;
    }

    .hero {
        min-height: 60vh;
    }

    .service-card {
        padding: 1.5rem;
    }

    .contact-form {
        padding: 1.5rem;
    }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s;
}

.modal.show {
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 12px;
    text-align: center;
    max-width: 500px;
    width: 90%;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.3s;
}

.modal-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
}

.modal-icon.success {
    background: #10B981;
    color: white;
}

.modal-icon.error {
    background: #EF4444;
    color: white;
}

.modal-content h3 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.modal-content p {
    color: var(--text);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.modal-content .btn {
    min-width: 120px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Cookie Consent Banner */
.cookie-consent {
    position: fixed;
    bottom: -200px;
    left: 0;
    right: 0;
    background: var(--white);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    padding: 1.5rem 0;
    z-index: 9999;
    transition: bottom 0.4s ease;
    transform: translateZ(0); /* Force hardware acceleration for mobile */
}

.cookie-consent.show {
    bottom: 0;
}

/* Force hide when dismissed - important for mobile Safari */
.cookie-consent[style*="display: none"] {
    display: none !important;
    bottom: -200px !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* Complete override for hidden state */
.cookie-consent[data-hidden="true"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    bottom: -200px !important;
    transform: translateY(100%) !important;
    transition: none !important;
    height: 0 !important;
    overflow: hidden !important;
    pointer-events: none !important;
    z-index: -1 !important;
}

.cookie-content {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.cookie-text h4 {
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.cookie-text p {
    color: var(--text);
    line-height: 1.5;
    margin: 0;
    font-size: 0.95rem;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-shrink: 0;
}

.btn-cookie {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    white-space: nowrap;
}

.btn-cookie-accept {
    background: var(--primary);
    color: white;
    touch-action: manipulation;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
    min-height: 44px; /* Ensures minimum touch target size */
    min-width: 100px;
}

.btn-cookie-accept:hover,
.btn-cookie-accept:active,
.btn-cookie-accept:focus {
    background: #1E3A8A;
    outline: none;
}

.btn-cookie-reject {
    background: transparent;
    color: var(--text);
    border: 1px solid #E5E7EB;
}

.btn-cookie-reject:hover {
    background: #F9FAFB;
}

.btn-cookie-settings {
    background: transparent;
    color: var(--primary);
    text-decoration: underline;
    padding: 0.6rem 0;
}

.btn-cookie-settings:hover {
    color: #1E3A8A;
}

/* Cookie Settings Modal */
.cookie-settings-content {
    max-width: 600px;
    padding: 2rem;
}

.cookie-settings-content h3 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.cookie-settings-content > p {
    color: var(--text);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.cookie-category {
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

.cookie-category h4 {
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.cookie-category p {
    color: var(--text);
    font-size: 0.9rem;
    line-height: 1.4;
    margin: 0;
}

/* Cookie Toggle Switch */
.cookie-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
    flex-shrink: 0;
}

.cookie-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #CBD5E1;
    transition: 0.3s;
    border-radius: 24px;
}

.cookie-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.cookie-switch input:checked + .cookie-slider {
    background-color: var(--primary);
}

.cookie-switch input:checked + .cookie-slider:before {
    transform: translateX(24px);
}

.cookie-switch input:disabled + .cookie-slider {
    opacity: 0.6;
    cursor: not-allowed;
}

.cookie-settings-buttons {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #E5E7EB;
}

/* Responsive Cookie Consent */
@media (max-width: 768px) {
    .cookie-content {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }

    .cookie-buttons {
        flex-direction: column;
        width: 100%;
    }

    .btn-cookie {
        width: 100%;
        justify-content: center;
    }

    .cookie-category-header {
        flex-direction: column;
        gap: 1rem;
    }

    .cookie-switch {
        align-self: flex-start;
    }

    .cookie-settings-buttons {
        flex-direction: column;
    }

    .cookie-settings-buttons button {
        width: 100%;
    }
}