﻿/* =========================================================
   Absolute Events - Site Styles (clean + structured)
   Order:
   1) Design tokens
   2) Resets / base
   3) Typography
   4) Layout containers / sections
   5) Home hero (background + content)
   6) Header / navigation
   7) Components (forms, buttons, uploads)
   8) Utilities
   9) Responsive
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700&display=swap');

/* ===== 1) Design tokens (colors, fonts, sizing) ===== */

:root {
    /* Fonts */
    --ae-font-body: "Open Sans", Arial, sans-serif;
    --ae-font-heading: "Playfair Display", serif;
    /* Colors */
    --ae-text: #1c1c1c;
    --ae-muted: #777;
    --ae-border: #ececec;
    --ae-accent: #c7a46a;
    --ae-accent-warm: #bfa782;
    --ae-accent-cool: #f4f4f4;
    --ae-accent-dark: #18191c;
    --ae-accent-hover: #b39158;
    --ae-input-bg: #fafafa;
    /* Layout */
    --ae-page-max: 1100px;
    --ae-header-max: 1250px;
    /* Header sizing */
    --ae-header-h: 110px;
    --ae-header-h-shrink: 75px;
    --ae-logo-h: 55px;
    --ae-logo-h-shrink: 42px;
    --ae-logo-w: 220px;
    /* Spacing */
    --ae-page-padding-x: 32px;
    --ae-section-padding-y: 80px;
    /* Hero */
    --ae-hero-h: 100dvh; /* full available viewport height */
    --ae-hero-overlay: 0.60;
    /* Scroll offset for anchor landing (match header height) */
    --ae-scroll-offset: 110px;
}

/* ===== 2) Resets / base ===== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

html {
    overflow-y: scroll;
    scroll-behavior: smooth;
    scroll-padding-top: var(--ae-scroll-offset);
}

body {
    font-family: var(--ae-font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--ae-text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

html, body {
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Links (global baseline) */
a {
    color: inherit;
    text-decoration: none;
}

/* ===== 3) Typography ===== */

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--ae-font-heading);
    font-weight: 800;
    line-height: 1.2;
    margin: 0 0 14px;
    color: var(--ae-text);
}

h1 {
    font-size: 48px;
}

h2 {
    font-size: 34px;
}

h3 {
    font-size: 24px;
    font-weight: 600;
}

h4 {
    font-size: 20px;
    font-weight: 600;
}

h5 {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

h6 {
    font-size: 13px;
    font-weight: 600;
}

p {
    margin: 0 0 16px;
}

.all-caps {
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.small-caps {
    font-variant: small-caps;
}

/* ===== 4) Layout containers / sections ===== */

.ae-page {
    max-width: var(--ae-page-max);
    margin: 0 auto;
    padding: 0 var(--ae-page-padding-x);
}

.ae-page--top-offset {
    padding-top: var(--ae-header-h);
}

/* Each section should land below the fixed header */
.ae-section {
    position: relative;
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    padding: var(--ae-section-padding-y) 0;
    background: #f6f7fb;
    scroll-margin-top: var(--ae-scroll-offset);
}

.ae-section--warm {
    background: #bfa782;
}

.ae-section--cool {
    background: #f4f4f4;
}

.ae-section--dark {
    background: #18191c;
    color: white;
}

    .ae-section--dark h1,
    .ae-section--dark h2,
    .ae-section--dark h3,
    .ae-section--dark h4,
    .ae-section--dark h5,
    .ae-section--dark h6 {
        color: white;
    }

/* Content canvas that scrolls over the hero */
.ae-home-content {
    position: relative;
    z-index: 2;
    background: #fff;
}

/* Purpose grid */
.ae-grid {
    display: grid;
    gap: 40px;
    margin-top: 40px;
}

.ae-grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ae-grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* Each column */
.ae-grid-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
    
    /* Optional: tighten headings */
    .ae-grid-item h3 {
        margin-bottom: 10px;
    }

.ae-grid-colspan-2 {
    grid-column: span 2;
}

.ae-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

    .ae-list p {
        margin: 0;
    }

.ae-card-media {
    width: 100%;
    height: 160px;
    border-radius: 10px;
    margin-bottom: 16px;
    display: grid;
    place-items: center;
}

.ae-icon-badge {
    width: 112px;
    height: 112px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    background: transparent;
    border: 2px solid rgba(56, 103, 130, 0.25);
    box-shadow: none;
    backdrop-filter: none;
}

.ae-icon {
    width: 40px;
    height: 40px;
    display: block;
}

/* ===== 5) Home hero (background slideshow + content) ===== */

/* Fixed background layer behind everything */
.ae-hero-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

/* Each slide fills the viewport */
.ae-hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 900ms ease;
    background: #111;
    background-image: linear-gradient( rgba(0, 0, 0, var(--ae-hero-overlay)), rgba(0, 0, 0, var(--ae-hero-overlay)) ), var(--ae-hero-img);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

    .ae-hero-slide.is-active {
        opacity: 1;
    }

/* Hero content fills the viewport */
.ae-hero {
    position: relative;
    z-index: 1;
    min-height: var(--ae-hero-h);
    height: var(--ae-hero-h);
    /* Push hero text down so it does not sit under the fixed header */
    padding-top: var(--ae-header-h);
    display: grid;
    place-items: center;
    padding-left: var(--ae-page-padding-x);
    padding-right: var(--ae-page-padding-x);
}

/* Inner hero width */
.ae-hero__inner {
    max-width: var(--ae-header-max);
    width: 100%;
    text-align: center;
}

.ae-hero h1,
.ae-hero p {
    color: #fff;
}

.ae-hero p {
    font-size: 18px;
    margin-top: 10px;
}

/* Text fade */
.ae-hero-copy {
    transition: opacity 250ms ease, transform 250ms ease;
    opacity: 1;
    transform: translateY(0);
}

    .ae-hero-copy.is-fading {
        opacity: 0;
        transform: translateY(6px);
    }

/* ===== 6) Header / navigation ===== */

.ae-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    /* Scroll-driven variable (0 -> 1) */
    --ae-size-t: 0;
    --ae-color-t: 0;
    background: rgba(255, 255, 255, var(--ae-color-t));
    border-bottom: 1px solid rgba(236, 236, 236, var(--ae-color-t));
    height: calc( var(--ae-header-h) - ((var(--ae-header-h) - var(--ae-header-h-shrink)) * var(--ae-size-t)) );
    display: flex;
    align-items: center;
}

/*
   If you previously had a spacer element in MainLayout, you can remove it now.
   Keep this class only if you still use it somewhere.
*/
.ae-header-spacer {
    height: var(--ae-header-h);
}

.ae-header-inner {
    max-width: var(--ae-header-max);
    margin: 0 auto;
    width: 100%;
    padding: 0 var(--ae-page-padding-x);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo */
.ae-logo {
    position: relative;
    display: inline-block;
}

    .ae-logo > a {
        position: relative;
        display: block;
        text-align: left;
        height: calc( var(--ae-logo-h) - ((var(--ae-logo-h) - var(--ae-logo-h-shrink)) * var(--ae-size-t)) );
        width: var(--ae-logo-w);
    }

    /* Overlapped images */
    .ae-logo img {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: contain;
        object-position: left center;
        transition: opacity 200ms ease;
    }

/* Fade rules (scroll driven) */
.ae-logo--light {
    opacity: calc(1 - var(--ae-color-t));
}

.ae-logo--dark {
    opacity: var(--ae-color-t);
}

/* Navigation */
.ae-nav {
    display: flex;
    gap: 28px;
    align-items: center;
    font-family: var(--ae-font-heading);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.2px;
}

    /* Scroll-driven blend: white -> black */
    .ae-nav a,
    .ae-nav .nav-link {
        padding: 8px 0 5px;
        position: relative;
        display: inline-block;
        color: rgb( calc(255 - (255 * var(--ae-color-t))), calc(255 - (255 * var(--ae-color-t))), calc(255 - (255 * var(--ae-color-t))) ) !important;
    }

        /* Underline bar */
        .ae-nav a::after,
        .ae-nav .nav-link::after {
            content: "";
            position: absolute;
            left: 0;
            bottom: 0;
            width: 0;
            height: 2px;
            background: var(--ae-accent);
            transition: width 0.2s ease;
        }

        .ae-nav a.active::after,
        .ae-nav .nav-link.active::after,
        .ae-nav a:hover::after,
        .ae-nav .nav-link:hover::after {
            width: 100%;
        }

/* Dropdown / expanded menu safety (Bootstrap-friendly) */
.ae-header:not(.ae-header--shrink) .dropdown-menu {
    background: rgba(0, 0, 0, 0);
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

    .ae-header:not(.ae-header--shrink) .dropdown-menu .dropdown-item {
        color: #fff;
    }

.ae-header.ae-header--shrink .dropdown-menu {
    background: #fff;
    border: 1px solid var(--ae-border);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

    .ae-header.ae-header--shrink .dropdown-menu .dropdown-item {
        color: #000;
    }

/* Optional social icons area */
.ae-icons {
    display: flex;
    gap: 14px;
    font-size: 18px;
    color: rgb( calc(255 - (255 * var(--ae-color-t))), calc(255 - (255 * var(--ae-color-t))), calc(255 - (255 * var(--ae-color-t))) );
}

/* ===== 7) Components ===== */

/* Forms */
.ae-form {
    max-width: 700px;
    margin: 0 auto;
    background: #fff;
    padding: 48px;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.05);
    font-family: var(--ae-font-body);
}

    .ae-form.ae-form-grid {
        max-width: none; /* allow expansion in grid layouts */
        width: 100%;
        margin: 0; /* don't center inside a grid cell */
    }

.ae-field {
    margin-bottom: 22px;
}

.ae-form label,
.ae-photo-field label {
    display: block;
    margin-bottom: 6px;
    color: var(--ae-muted);
    text-transform: uppercase;
}

/* Form label variants */
.ae-form label {
    font-size: 12px;
    letter-spacing: 1.2px;
    font-weight: 600;
}

.ae-photo-field label {
    font-size: 11px;
    letter-spacing: 1px;
    font-weight: 700;
}

.ae-form input,
.ae-form textarea,
.ae-form select,
.ae-input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    font-size: 15px;
    font-family: inherit;
    background: var(--ae-input-bg);
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

    .ae-form input:focus,
    .ae-form textarea:focus,
    .ae-form select:focus,
    .ae-input:focus {
        outline: none;
        border-color: var(--ae-accent);
        background: #fff;
        box-shadow: 0 0 0 2px rgba(199, 164, 106, 0.15);
    }

/* Checklist */
.ae-checklist {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 22px;
    margin-top: 8px;
}

    .ae-checklist .ae-checkitem {
        display: flex;
        align-items: center;
        gap: 14px;
        margin: 0;
        font-size: 15px;
        font-weight: 500;
        color: var(--ae-text);
        cursor: pointer;
    }

        .ae-checklist .ae-checkitem input[type="checkbox"] {
            width: 22px;
            height: 22px;
            margin: 0;
            border-radius: 6px;
            accent-color: var(--ae-accent);
            cursor: pointer;
        }

        .ae-checklist .ae-checkitem span {
            line-height: 1.3;
        }

/* Buttons */
.ae-btn {
    background: var(--ae-accent);
    color: #fff;
    border: none;
    padding: 14px 28px;
    font-size: 14px;
    font-family: var(--ae-font-heading);
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.25s ease;
}

    .ae-btn:hover {
        background: var(--ae-accent-hover);
    }

.ae-btn--secondary {
    background: #f1f1f1;
    color: var(--ae-text);
}

    .ae-btn--secondary:hover {
        background: #e6e6e6;
    }

/* Portfolio upload list */
.ae-photo-list {
    display: grid;
    gap: 14px;
}

.ae-photo-row {
    display: grid;
    grid-template-columns: 110px 1fr auto;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--ae-border);
    border-radius: 10px;
    background: #fff;
}

.ae-photo-thumb {
    width: 110px;
    height: 110px;
    border-radius: 10px;
    overflow: hidden;
    background: var(--ae-input-bg);
    border: 1px solid #e5e5e5;
    display: grid;
    place-items: center;
}

    .ae-photo-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.ae-photo-name {
    font-family: var(--ae-font-heading);
    font-weight: 700;
    margin-bottom: 4px;
}

.ae-photo-meta {
    font-size: 13px;
    margin-bottom: 10px;
    color: var(--ae-muted);
    display: flex;
    gap: 10px;
    align-items: center;
}

.ae-photo-fields {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    min-width: 0;
    align-items: stretch;
}

    .ae-photo-fields .ae-input {
        height: 46px;
    }

.ae-photo-key {
    font-size: 12px;
    margin-top: 10px;
}

.ae-photo-actions {
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
}

/* ===== 8) Utilities ===== */

.ae-text-center {
    text-align: center;
}

.ae-muted {
    color: var(--ae-muted);
}

.ae-curve-top {
    clip-path: ellipse(160% 100% at 50% 100%);
}

.ae-curve-bottom {
    clip-path: ellipse(160% 100% at 50% 0%);
}

/* ===== 9) Responsive ===== */

/* Add rules here when you are ready, for example:
@media (max-width: 768px) { ... }
*/


@media (max-width: 900px) {
    .ae-purpose-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .ae-purpose-grid {
        grid-template-columns: 1fr;
    }
}