/* Hui Feng Shui - Global Design System */

:root {
    /* Colors */
    --hui-gold: #c9a44b;
    --hui-gold-dark: #8b6914;
    --hui-gold-light: #d4b76a;
    --hui-brown-dark: #3b2f1a;
    --hui-brown-body: #2c2416;
    --hui-brown-sub: #5a4a2f;
    --hui-brown-accent: #5a3e1b;
    --hui-cream: #fdfbf5;
    --hui-warm-white: #faf7f0;
    --hui-border: #e8dcc4;
    --hui-border-light: #e0d5b8;
    --hui-cta-start: #faf7f0;
    --hui-cta-end: #f0e6d2;

    /* Typography */
    --hui-font: "Lora", "Georgia", serif;
    --hui-font-sans: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
    --hui-line-height: 1.8;
    --hui-letter-spacing: 0.01em;

    /* Spacing */
    --hui-section-padding: clamp(80px, 10vw, 140px);
    --hui-content-max: 1000px;
    --hui-text-max: 720px;

    /* Transitions */
    --hui-ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --hui-duration: 0.6s;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.hui-page {
    font-family: var(--hui-font);
    color: var(--hui-brown-body);
    line-height: var(--hui-line-height);
    letter-spacing: var(--hui-letter-spacing);
    background: #ffffff;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Typography Scale */
.hui-page h1 {
    font-size: clamp(2.4rem, 5vw, 3.6rem);
    font-weight: 400;
    line-height: 1.2;
    color: var(--hui-brown-dark);
    letter-spacing: -0.02em;
}

.hui-page h2 {
    font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    font-weight: 400;
    line-height: 1.3;
    color: var(--hui-brown-dark);
    letter-spacing: -0.01em;
}

.hui-page h3 {
    font-size: clamp(1.2rem, 2vw, 1.5rem);
    font-weight: 600;
    line-height: 1.4;
    color: var(--hui-brown-accent);
}

.hui-page p {
    font-size: clamp(1rem, 1.1vw, 1.1rem);
    margin-bottom: 1.5em;
    color: var(--hui-brown-sub);
}

/* Links */
.hui-page a {
    color: var(--hui-gold-dark);
    text-decoration: none;
    transition: color 0.3s var(--hui-ease);
}
.hui-page a:hover {
    color: var(--hui-gold);
}

/* Sections */
.hui-section {
    padding: var(--hui-section-padding) 24px;
    position: relative;
}
.hui-section--cream {
    background: var(--hui-cream);
}
.hui-section--warm {
    background: var(--hui-warm-white);
}

.hui-container {
    max-width: var(--hui-content-max);
    margin: 0 auto;
}

.hui-text-container {
    max-width: var(--hui-text-max);
}

/* Decorative Elements */
.hui-divider {
    width: 60px;
    height: 2px;
    background: var(--hui-gold);
    margin: 24px 0;
}
.hui-divider--center {
    margin-left: auto;
    margin-right: auto;
}

/* Buttons */
.hui-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 16px 40px;
    border-radius: 30px;
    font-family: var(--hui-font-sans);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-decoration: none;
    transition: all 0.3s var(--hui-ease);
    cursor: pointer;
    border: none;
}
.hui-btn--primary {
    background: var(--hui-gold);
    color: #ffffff;
}
.hui-btn--primary:hover {
    background: var(--hui-gold-dark);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(201, 164, 75, 0.3);
}
.hui-btn--outline {
    background: transparent;
    color: var(--hui-gold-dark);
    border: 1.5px solid var(--hui-gold);
}
.hui-btn--outline:hover {
    background: var(--hui-gold);
    color: #ffffff;
    transform: translateY(-2px);
}

/* Cards */
.hui-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 40px 32px;
    border-top: 3px solid var(--hui-gold);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    transition: transform 0.4s var(--hui-ease), box-shadow 0.4s var(--hui-ease);
}
.hui-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

/* Scroll Animations */
.hui-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity var(--hui-duration) var(--hui-ease), transform var(--hui-duration) var(--hui-ease);
}
.hui-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.hui-reveal--delay-1 { transition-delay: 0.1s; }
.hui-reveal--delay-2 { transition-delay: 0.2s; }
.hui-reveal--delay-3 { transition-delay: 0.3s; }
.hui-reveal--delay-4 { transition-delay: 0.4s; }

/* Responsive */
@media (max-width: 768px) {
    .hui-section {
        padding: 60px 20px;
    }
    .hui-card {
        padding: 28px 24px;
    }
}

/* ============================================================
   Navigation
   ============================================================ */
.hui-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 24px 32px;
    transition: all 0.4s var(--hui-ease);
}
.hui-nav--scrolled {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 14px 32px;
    box-shadow: 0 1px 20px rgba(59, 47, 26, 0.06);
}
.hui-nav__inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.hui-nav__brand {
    text-decoration: none;
}
.hui-nav__brand-text {
    font-family: var(--hui-font);
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--hui-brown-dark);
    letter-spacing: 0.02em;
}
.hui-nav__menu {
    display: flex;
    list-style: none;
    gap: 40px;
    margin: 0;
    padding: 0;
}
.hui-nav__menu a {
    font-family: var(--hui-font-sans);
    font-size: 0.88rem;
    font-weight: 450;
    color: var(--hui-brown-sub);
    text-decoration: none;
    letter-spacing: 0.02em;
    transition: color 0.3s var(--hui-ease);
    position: relative;
}
.hui-nav__menu a::after {
    content: "";
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: var(--hui-gold);
    transition: width 0.3s var(--hui-ease);
}
.hui-nav__menu a:hover {
    color: var(--hui-brown-dark);
}
.hui-nav__menu a:hover::after {
    width: 100%;
}
.hui-nav__cta {
    padding: 10px 28px;
    font-size: 0.82rem;
}
.hui-nav__toggle {
    outline: none;
    -webkit-appearance: none;
    -webkit-tap-highlight-color: transparent;
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}
.hui-nav__toggle:focus,
.hui-nav__toggle:active,
.hui-nav__toggle:focus-visible {
    outline: none !important;
    outline-style: none !important;
    box-shadow: none !important;
    border: none !important;
    -webkit-tap-highlight-color: transparent !important;
}
.hui-nav__toggle span {
    display: block;
    width: 22px;
    height: 1.5px;
    background: var(--hui-brown-dark);
    transition: all 0.3s var(--hui-ease);
}
.hui-nav__toggle.is-active span:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}
.hui-nav__toggle.is-active span:nth-child(2) {
    opacity: 0;
}
.hui-nav__toggle.is-active span:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
}

@media (max-width: 768px) {
    .hui-nav { padding: 16px 20px; }
    .hui-nav--scrolled { padding: 12px 20px; }
    .hui-nav__menu {
        position: fixed;
        top: 0; right: -100%;
        width: 280px; height: 100vh;
        background: #ffffff;
        flex-direction: column;
        padding: 100px 40px 40px;
        gap: 28px;
        box-shadow: -4px 0 30px rgba(0,0,0,0.1);
        transition: right 0.4s var(--hui-ease);
    }
    .hui-nav__menu.is-open { right: 0; }
    .hui-nav__menu a { font-size: 1rem; }
    .hui-nav__cta { display: none; }
    .hui-nav__toggle { display: flex; }
}

/* ============================================================
   Footer
   ============================================================ */
.hui-footer {
    background: var(--hui-brown-dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 80px 32px 40px;
}
.hui-footer__inner {
    max-width: 1000px;
    margin: 0 auto;
}
.hui-footer__grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}
.hui-footer__brand {
    font-family: var(--hui-font);
    font-size: 1.3rem;
    font-weight: 600;
    color: #ffffff;
    display: block;
    margin-bottom: 12px;
}
.hui-footer__tagline {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 20px;
    line-height: 1.6;
}
.hui-footer__contact a {
    color: var(--hui-gold-light);
    font-size: 0.9rem;
}
.hui-footer__contact a:hover {
    color: var(--hui-gold);
}
.hui-footer__heading {
    font-family: var(--hui-font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 20px;
}
.hui-footer__links {
    list-style: none;
    padding: 0;
    margin: 0;
}
.hui-footer__links li {
    margin-bottom: 12px;
}
.hui-footer__links a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    text-decoration: none;
    transition: color 0.3s var(--hui-ease);
}
.hui-footer__links a:hover {
    color: #ffffff;
}
.hui-footer__bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    text-align: center;
}
.hui-footer__bottom p {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.35);
    margin: 0;
}

@media (max-width: 768px) {
    .hui-footer { padding: 60px 20px 30px; }
    .hui-footer__grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

/* ============================================================
   Override Astra defaults - Force layout
   ============================================================ */
body.hui-page .hui-nav__inner {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-direction: row !important;
}
body.hui-page ul.hui-nav__menu {
    display: flex !important;
    flex-direction: row !important;
    list-style: none !important;
    gap: 40px !important;
    margin: 0 !important;
    padding: 0 !important;
}
body.hui-page .hui-footer__grid {
    display: grid !important;
    grid-template-columns: 2fr 1fr 1fr !important;
    gap: 60px !important;
}
body.hui-page .hui-footer__links {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}
body.hui-page .hui-credentials {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
}
body.hui-page .hui-services-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)) !important;
    gap: 24px !important;
}
body.hui-page .hui-testimonials {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
    gap: 32px !important;
}
body.hui-page .hui-hero__actions {
    display: flex !important;
    gap: 16px !important;
    justify-content: center !important;
    flex-wrap: wrap !important;
}
@media (max-width: 768px) {
    body.hui-page ul.hui-nav__menu {
        flex-direction: column !important;
        position: fixed !important;
        top: 0 !important;
        right: -100% !important;
        width: 280px !important;
        height: 100vh !important;
        background: #ffffff !important;
        padding: 100px 40px 40px !important;
        gap: 28px !important;
    }
    body.hui-page ul.hui-nav__menu.is-open {
        right: 0 !important;
    }
    body.hui-page .hui-footer__grid {
        grid-template-columns: 1fr !important;
        gap: 40px !important;
    }
    body.hui-page .hui-credentials {
        flex-wrap: wrap !important;
        gap: 24px !important;
    }
}

/* === FOCUS STATE OVERRIDES ===
   Force focus states to look identical to normal states.
   Prevents color change on click for scroll-to-top and nav toggle. */
body.hui-page #ast-scroll-top,
body.hui-page #ast-scroll-top:focus,
body.hui-page #ast-scroll-top:active,
body.hui-page #ast-scroll-top:focus-visible,
body.hui-page #ast-scroll-top:focus-within {
    background-color: #c9a44b !important;
    color: #ffffff !important;
    outline: none !important;
    outline-style: none !important;
    outline-width: 0 !important;
    box-shadow: none !important;
    border: none !important;
    border-style: none !important;
    border-width: 0 !important;
    border-color: transparent !important;
    -webkit-tap-highlight-color: transparent !important;
}
body.hui-page #ast-scroll-top:hover {
    background-color: #8b6914 !important;
}
body.hui-page .hui-nav__toggle,
body.hui-page .hui-nav__toggle:focus,
body.hui-page .hui-nav__toggle:active,
body.hui-page .hui-nav__toggle:focus-visible {
    background: none !important;
    outline: none !important;
    outline-style: none !important;
    outline-width: 0 !important;
    box-shadow: none !important;
    border: none !important;
    border-style: none !important;
    border-width: 0 !important;
    border-color: transparent !important;
    -webkit-tap-highlight-color: transparent !important;
}
body.hui-page button:focus,
body.hui-page button:active,
body.hui-page button:focus-visible {
    outline: none !important;
    outline-style: none !important;
    box-shadow: none !important;
    border-color: transparent !important;
    -webkit-tap-highlight-color: transparent !important;
}

/* Mobile menu toggle - override browser focus outline */
.menu-toggle:focus,
.menu-toggle:active,
.ast-mobile-menu-trigger-minimal:focus,
.ast-mobile-menu-trigger-minimal:active,
.ast-button-wrap .menu-toggle:focus,
[data-section="section-header-mobile-trigger"] .menu-toggle:focus {
    outline: none !important;
    box-shadow: none !important;
    color: #c9a44b !important;
    border-color: #c9a44b !important;
}
.menu-toggle:hover,
.ast-mobile-menu-trigger-minimal:hover {
    color: #8b6914 !important;
    border-color: #8b6914 !important;
}

/* Override all Astra button focus states */
body button:focus,
body .ast-button:focus,
body input[type="submit"]:focus,
body input[type="button"]:focus {
    outline-color: #c9a44b !important;
}
