@import "tailwindcss";

/* ============================================================
   EMAR THEME - CUSTOM PROPERTIES
   ============================================================ */
@theme {
    --color-primary-50:  #e8f2f7;
    --color-primary-100: #d1e5ef;
    --color-primary-200: #a3cbdf;
    --color-primary-300: #75b1cf;
    --color-primary-400: #4997bf;
    --color-primary-500: #24638d;
    --color-primary-600: #1d4f71;
    --color-primary-700: #163b55;
    --color-primary-800: #0e2738;
    --color-primary-900: #07131c;
    --color-secondary-500: #1a5276;
    --color-secondary-600: #154360;

    --font-heading: 'Poppins', sans-serif;
    --font-body:    'Inter', sans-serif;
}

/* ============================================================
   BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    overflow-x: hidden;
    color: #111827;
    background: #fff;
}

.font-heading { font-family: var(--font-heading); }

/* ============================================================
   GRADIENTS & COLOUR HELPERS
   ============================================================ */
.gradient-bg {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
}

.gradient-text {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-primary {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    border-radius: 9999px;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(36,99,141,0.4);
    color: #fff;
}

.btn-secondary {
    border: 2px solid #24638d;
    color: #24638d;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    border-radius: 9999px;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    background: #fff;
}
.btn-secondary:hover {
    background: #24638d;
    color: #fff;
    transform: translateY(-2px);
}

/* ============================================================
   TOP BAR (contact strip above header)
   ============================================================ */
#top-bar {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
}

/* ============================================================
   HEADER
   ============================================================ */
#site-header {
    transition: all 0.3s ease;
}
#site-header.scrolled {
    box-shadow: 0 4px 30px rgba(0,0,0,0.12);
}

/* ============================================================
   MEGA MENU
   ============================================================ */
.mega-menu-panel {
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.2s ease;
}
.mega-menu-panel.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* ============================================================
   MOBILE MENU
   ============================================================ */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}
#mobile-menu.open {
    max-height: 800px;
}

/* ============================================================
   HERO
   ============================================================ */
.hero-section {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 50%, #0e2738 100%);
    position: relative;
    overflow: hidden;
}
.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* ============================================================
   CARDS
   ============================================================ */
.card-hover {
    transition: all 0.3s ease;
}
.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.12);
}

/* ============================================================
   LOGO TICKER
   ============================================================ */
.ticker-track {
    display: flex;
    width: max-content;
    animation: ticker 35s linear infinite;
}
.ticker-track:hover { animation-play-state: paused; }

@keyframes ticker {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50%       { transform: translateY(-12px); }
}

.animate-fade-in-up { animation: fadeInUp 0.7s ease-out forwards; }
.animate-float      { animation: float 4s ease-in-out infinite; }

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }
.opacity-0 { opacity: 0; }

/* ============================================================
   VIDEO PLAY BUTTON
   ============================================================ */
.video-overlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 80px; height: 80px;
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(36,99,141,0.5);
}
.video-overlay:hover {
    transform: translate(-50%,-50%) scale(1.1);
    box-shadow: 0 15px 40px rgba(36,99,141,0.7);
}

/* ============================================================
   TABS (flexible content module)
   ============================================================ */
.tab-btn.active {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(36,99,141,0.3);
}

/* ============================================================
   ACCORDION
   ============================================================ */
.accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
}
.accordion-body.open {
    max-height: 600px;
}

/* ============================================================
   GRAVITY FORMS BASE OVERRIDE
   ============================================================ */
.gform_wrapper .gform_body .gfield input:not([type=radio]):not([type=checkbox]):not([type=submit]):not([type=button]):not([type=image]):not([type=file]),
.gform_wrapper .gform_body .gfield select,
.gform_wrapper .gform_body .gfield textarea {
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    width: 100%;
    font-family: var(--font-body);
    transition: border-color 0.2s, box-shadow 0.2s;
}
.gform_wrapper .gform_body .gfield input:focus,
.gform_wrapper .gform_body .gfield select:focus,
.gform_wrapper .gform_body .gfield textarea:focus {
    outline: none;
    border-color: #24638d;
    box-shadow: 0 0 0 3px rgba(36,99,141,0.15);
}
.gform_wrapper .gform_footer input[type=submit],
.gform_wrapper .gform_page_footer input[type=submit] {
    background: linear-gradient(135deg, #24638d 0%, #1a5276 100%);
    color: #fff;
    border: none;
    border-radius: 9999px;
    padding: 0.875rem 2rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body);
}
.gform_wrapper .gform_footer input[type=submit]:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(36,99,141,0.4);
}

/* ============================================================
   SCROLL-REVEAL (JS hooks)
   ============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   BLOG POST CONTENT STYLING
   ============================================================ */
.prose {
    /* Paragraph spacing */
    & p {
        margin-bottom: 1.5rem;
        line-height: 1.75;
    }
    
    /* List spacing and bullets */
    & ul {
        margin-top: 1.5rem;
        margin-bottom: 1.5rem;
        list-style-type: disc;
        padding-left: 1.5rem;
    }
    
    & ul li {
        margin-bottom: 0.75rem;
        line-height: 1.75;
        padding-left: 0.5rem;
    }
    
    & ol {
        margin-top: 1.5rem;
        margin-bottom: 1.5rem;
        list-style-type: decimal;
        padding-left: 1.5rem;
    }
    
    & ol li {
        margin-bottom: 0.75rem;
        line-height: 1.75;
        padding-left: 0.5rem;
    }
    
    /* Headings spacing */
    & h1 {
        margin-top: 2rem;
        margin-bottom: 1.5rem;
        font-weight: 700;
        font-size: 2.25rem;
        line-height: 1.2;
    }
    
    & h2 {
        margin-top: 2.5rem;
        margin-bottom: 1.5rem;
        font-weight: 700;
        font-size: 1.875rem;
        line-height: 1.3;
    }
    
    & h3 {
        margin-top: 2rem;
        margin-bottom: 1rem;
        font-weight: 600;
        font-size: 1.5rem;
        line-height: 1.4;
    }
    
    & h4 {
        margin-top: 1.5rem;
        margin-bottom: 0.75rem;
        font-weight: 600;
        font-size: 1.25rem;
        line-height: 1.4;
    }
    
    & h5 {
        margin-top: 1rem;
        margin-bottom: 0.75rem;
        font-weight: 600;
        font-size: 1.125rem;
        line-height: 1.5;
    }
    
    & h6 {
        margin-top: 1rem;
        margin-bottom: 0.5rem;
        font-weight: 600;
        font-size: 1rem;
        line-height: 1.5;
    }
    
    /* Desktop responsive headings */
    @media (min-width: 1024px) {
        & h1 {
            font-size: 3rem;
        }
        & h2 {
            font-size: 2.25rem;
        }
        & h3 {
            font-size: 1.875rem;
        }
        & h4 {
            font-size: 1.5rem;
        }
        & h5 {
            font-size: 1.25rem;
        }
        & h6 {
            font-size: 1.125rem;
        }
    }
}

/* ============================================================
   PRINT
   ============================================================ */
@media print {
    #top-bar, #site-header, #cookie-banner, .btn-primary, .btn-secondary { display: none !important; }
}
