/* pages.css — page-specific styles and shared component styles.
 * Colors come from colors.css. Do not add hex values here.
 */

/* ═══════════════════════════════════════════════════════════════════════════
   HOME HERO
   ═══════════════════════════════════════════════════════════════════════════ */

@keyframes fade-up {
    from { opacity: 0; transform: translateY(28px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Hero shell ──────────────────────────────────────────────────────────── */
/* Fixed viewport height minus the sticky nav so everything fits in one screen */
.hero {
    position: relative;
    width: 100%;           /* prevent the headline from stretching the box */
    height: calc(100vh - var(--nav-height));
    min-height: 640px;
    overflow: hidden;
    background-color: var(--color-light);
}

/* Gradient fade — blends the portrait's cut bottom edge into the hero bg */
.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: clamp(140px, 20vh, 220px);
    background: linear-gradient(to top, var(--color-light) 0%, transparent 100%);
    z-index: 2;
    pointer-events: none;
}

/* ── Top area: badge + headline ──────────────────────────────────────────── */
/* z-index 1 — the portrait (z-index 2) will float on top of this */
.hero-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    padding-top: clamp(var(--space-8), 5vh, var(--space-12));
    padding-inline: var(--space-6);
    position: relative;
    z-index: 1;
}

/* ── Badge ────────────────────────────────────────────────────────────────── */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    background-color: var(--color-primary-light);
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
    border-radius: var(--radius-pill);
    padding: 8px 22px;
    font-size: 1rem;
    font-weight: 600;
    animation: fade-up 0.45s ease-out 0s both;
}

.hero-badge-wave {
    display: inline-block;
    font-style: normal;
}

/* ── Headline ────────────────────────────────────────────────────────────── */
/* Large enough to span the full viewport width, matching the Jenny reference */
.hero-headline {
    font-size: clamp(3rem, 11vw, 7rem);
    font-weight: 800;
    line-height: 1.0;
    text-align: center;
    color: var(--color-dark);
    letter-spacing: -0.05em;
    margin: 0;
    animation: fade-up 0.5s ease-out 0.1s both;
}

.hero-headline-accent {
    color: var(--color-nav-dark-red);
}

/* ── Portrait: absolute, bottom-anchored, overlaps the headline ──────────── */
/* z-index 2 so it renders on top of the headline text.
 * left:0 right:0 margin:auto centres against the viewport, not the text box,
 * avoiding the off-centre shift caused by headline overflow. */
.hero-portrait-wrap {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    margin-inline: auto;
    width: clamp(280px, 38vw, 460px);
    height: clamp(380px, 78vh, 740px);
    z-index: 2;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    animation: fade-up 0.6s ease-out 0.15s both;
}

/* Solid circle — the bold "stage" the person stands on */
.hero-portrait-circle {
    position: absolute;
    bottom: -25px;
    left: 50%;
    transform: translateX(-50%);
    width: clamp(272px, 37.4vw, 442px);
    height: clamp(272px, 37.4vw, 442px);
    border-radius: 50%;
    background-color: var(--color-nav-dark-red);
    opacity: 1;
}

.hero-portrait-img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: bottom center;
}

/* ── Bottom bar: [left] | [CTAs] | [right] ───────────────────────────────── */
/* Absolutely positioned so it floats over the lower part of the portrait    */
/* bottom: 26% places it approximately at waist level of the portrait        */
.hero-bottom {
    position: absolute;
    bottom: 26%;
    left: 0;
    right: 0;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: flex-end;
    z-index: 3;
    pointer-events: none; /* prevent phantom click zones; children re-enable */
}

.hero-bottom > * {
    pointer-events: auto;
}

/* ── Side columns ────────────────────────────────────────────────────────── */
.hero-side {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
}

.hero-side--left {
    align-items: flex-start;
    text-align: left;
    padding-left: clamp(2rem, 7vw, 9rem);
    position: relative;
    top: 1vh;
    animation: fade-up 0.5s ease-out 0.28s both;
}

.hero-side--right {
    align-items: flex-end;
    text-align: right;
    padding-right: clamp(2rem, 7vw, 9rem);
    animation: fade-up 0.5s ease-out 0.32s both;
}

/* ── Testimonial quote ────────────────────────────────────────────────────── */
.hero-quote {
    max-width: 280px;
}

.hero-quote-mark {
    display: block;
    font-size: 4.5rem;
    line-height: 0.5;
    color: var(--color-primary);
    font-family: Georgia, serif;
    margin-bottom: var(--space-3);
    opacity: 0.8;
}

.hero-quote p {
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--color-text-main);
    margin-bottom: 0;
}

/* Author hidden on desktop — shows on mobile where space isn't a concern */
.hero-quote-author {
    display: none;
}

/* ── Stat ─────────────────────────────────────────────────────────────────── */
.hero-stat {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.hero-stat-number {
    font-size: clamp(2.5rem, 5vw, 3.25rem);
    font-weight: 800;
    color: var(--color-dark);
    line-height: 1;
    letter-spacing: -0.03em;
}

.hero-stat-label {
    font-size: 1.0625rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

/* ── Credential (right side) — no card, plain text like the reference ──────── */
.hero-credential {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: var(--space-1);
}

/* CSS ★ stars in brand colour instead of yellow emoji */
.hero-stars {
    font-size: 1.5rem;
    color: var(--color-primary);
    letter-spacing: 0.05em;
    margin-bottom: var(--space-2);
}

.hero-credential-label {
    display: none;
}

.hero-credential-value {
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 800;
    color: var(--color-dark);
    line-height: 1.05;
    letter-spacing: -0.03em;
    margin: 0;
}

/* Thin-line separator + smaller word below the number, matching Jenny's "Experts" */
.hero-credential-sub {
    display: block;
    font-size: 1.125rem;
    font-weight: 400;
    color: var(--color-text-muted);
    padding-top: var(--space-2);
    border-top: 2px solid var(--color-border);
    margin-top: var(--space-2);
}

/* ── CTA buttons ─────────────────────────────────────────────────────────── */
.hero-ctas {
    display: flex;
    gap: var(--space-3);
    align-items: center;
    justify-content: center;
    position: relative;
    top: 18vh;
    animation: fade-up 0.5s ease-out 0.42s both;
}

.btn-hero-primary,
.btn-hero-secondary {
    border-radius: var(--radius-pill);
    padding: 16px 34px;
    font-size: 1.0625rem;
    font-weight: 700;
    white-space: nowrap;
    background-color: var(--color-white);
    text-decoration: none;
    display: inline-block;
}

/* BOTÓN PRINCIPAL */
.btn-hero-primary {
    color: var(--color-cta-primary-bg);
    border: 2px solid var(--color-cta-primary-bg);
    transition: background-color 0.18s, border-color 0.18s, color 0.18s;
}

.btn-hero-primary:hover {
    background-color: var(--color-cta-primary-bg);
    border-color: var(--color-cta-primary-bg);
    color: var(--color-white);
}

/* BOTÓN SECUNDARIO */
.btn-hero-secondary {
    color: var(--color-cta-secondary-text);
    border: 2px solid var(--color-cta-secondary-border);
    transition: background-color 0.18s, color 0.18s, border-color 0.18s;
}

.btn-hero-secondary:hover {
    background-color: var(--color-cta-secondary-border);
    border-color: var(--color-cta-secondary-border);
    color: var(--color-white);
}

/* ── Reduced motion ──────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .hero-badge,
    .hero-headline,
    .hero-portrait-wrap,
    .hero-side--left,
    .hero-side--right,
    .hero-ctas {
        animation: none;
    }
}

/* ── Mobile (≤ 900px): revert to stacked flow layout ────────────────────── */
@media (max-width: 900px) {
    .hero {
        height: auto;
        min-height: 100svh;
        padding-bottom: var(--space-10);
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero::after {
        display: none;
    }

    .hero-top {
        padding-top: var(--space-10);
    }

    .hero-portrait-wrap {
        position: static;
        transform: none;
        width: 260px;
        height: 360px;
        margin: var(--space-6) auto 0;
    }

    .hero-portrait-circle {
        width: 320px;
        height: 320px;
    }

    .hero-bottom {
        position: static;
        grid-template-columns: 1fr;
        gap: var(--space-6);
        padding-inline: var(--space-6);
        width: 100%;
        margin-top: var(--space-6);
    }

    .hero-side--left,
    .hero-side--right {
        align-items: center;
        text-align: center;
        padding-inline: 0;
        top: 0;
    }

    .hero-stat     { align-items: center; }
    .hero-credential { align-items: center; }

    /* Desktop's top: 18vh offset floats the CTAs over the portrait when
       .hero-bottom is absolutely positioned — once stacked in normal flow
       on mobile, that offset has nothing to float over and just pushes the
       buttons down into the next block. */
    .hero-ctas {
        justify-content: center;
        top: 0;
    }

    .hero-quote-author  { display: block; }
    .hero-credential-label { display: block; }

    .hero-headline {
        font-size: clamp(2.25rem, 9vw, 3.5rem);
    }
}

/* ── Wide + tall viewports (e.g. 1920×1080): cap hero to avoid filling the screen ── */
@media (min-height: 900px) and (min-width: 1280px) {
    .hero {
        height: 820px;
    }
    .hero-ctas {
        top: 140px; /* 18vh = 194px at 1080px would overflow; fixed value keeps CTAs visible */
    }
}

@media (max-width: 480px) {
    .hero-portrait-wrap {
        width: 220px;
        height: 300px;
    }

    .hero-portrait-circle {
        width: 280px;
        height: 280px;
    }

    .btn-hero-primary,
    .btn-hero-secondary {
        width: 100%;
        text-align: center;
    }

    .hero-ctas {
        flex-direction: column;
        width: 100%;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   PAGE HERO (inner pages)
   ═══════════════════════════════════════════════════════════════════════════ */

.page-hero {
    background-color: var(--color-bg-section);
    border-bottom: 1px solid var(--color-border);
    padding-block: var(--space-12);
    text-align: center;
}

.page-hero h1 {
    margin-bottom: var(--space-3);
}

.page-hero-subtitle {
    font-size: 1.1875rem;
    color: var(--color-text-muted);
    margin-bottom: 0;
}

/* ── Placeholder sections ─────────────────────────────────────────────────── */
.placeholder-section {
    background-color: var(--color-bg-section);
    border: 1px dashed var(--color-border);
    border-radius: var(--radius-lg);
    margin-bottom: var(--space-4);
}

.placeholder-text {
    color: var(--color-text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   CONTACT PAGE  (/contact)
   ═══════════════════════════════════════════════════════════════════════════ */

.contact-hero {
    background-color: var(--color-nav-dark-red);
    border-bottom: none;
    padding-block: clamp(3rem, 6vw, 5rem);
}

.contact-hero .page-hero-subtitle,
.contact-hero h1 {
    color: var(--color-white);
}

.contact-hero-eyebrow {
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--color-white);
    opacity: 0.65;
    margin: 0 0 var(--space-3) 0;
}

.contact-hero .page-hero-subtitle {
    opacity: 0.82;
    max-width: 520px;
    margin-inline: auto;
}

/* ── Two-column layout ────────────────────────────────────────────────────── */
.contact-section {
    background-color: var(--color-white);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(var(--space-8), 5vw, var(--space-16));
    align-items: start;
}

.contact-col-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-dark);
    margin: 0 0 var(--space-6) 0;
}

/* ── Form column ──────────────────────────────────────────────────────────── */
.contact-form {
    display: flex;
    flex-direction: column;
}

/* Honeypot — must be invisible to humans, accessible to bots */
.contact-botcheck {
    display: none !important;
}

/* ── Info column ──────────────────────────────────────────────────────────── */
.contact-info-cards {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    margin-bottom: var(--space-8);
}

.contact-info-card {
    display: flex;
    align-items: flex-start;
    gap: var(--space-4);
    padding: var(--space-4);
    background-color: var(--color-bg-section);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.contact-info-icon {
    flex-shrink: 0;
    width: 2.25rem;
    height: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-primary-light);
    color: var(--color-nav-dark-red);
    border-radius: var(--radius);
}

.contact-info-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-text-muted);
    margin: 0 0 2px 0;
}

.contact-info-value {
    font-size: 1rem;
    color: var(--color-text-main);
    text-decoration: none;
    font-weight: 500;
}

a.contact-info-value:hover {
    color: var(--color-nav-dark-red);
    text-decoration: underline;
}

/* ── What to expect ───────────────────────────────────────────────────────── */
.contact-expect {
    padding: var(--space-6);
    background-color: var(--color-primary-light);
    border-radius: var(--radius-lg);
    border-left: 3px solid var(--color-nav-dark-red);
}

.contact-expect-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-dark);
    margin: 0 0 var(--space-4) 0;
}

.contact-expect-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    list-style: none;
}

.contact-expect-list li {
    font-size: 1rem;
    color: var(--color-text-main);
    padding-left: var(--space-4);
    position: relative;
}

.contact-expect-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--color-nav-dark-red);
    font-weight: 700;
}

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

/* ═══════════════════════════════════════════════════════════════════════════
   BLOG — CARDS + SINGLE POST
   ═══════════════════════════════════════════════════════════════════════════ */

.post-card {
    background-color: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.2s;
}

.post-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.post-card-image-link {
    display: block;
    line-height: 0;
}

.post-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.post-card-body {
    padding: var(--space-6);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.post-card-date {
    font-size: 0.9375rem;
    color: var(--color-text-muted);
    display: block;
    margin-bottom: var(--space-2);
}

.post-card-title {
    font-size: 1.125rem;
    margin-bottom: var(--space-3);
}

.post-card-title a {
    text-decoration: none;
    color: var(--color-text-main);
}

.post-card-title a:hover {
    color: var(--color-primary);
}

.post-card-excerpt {
    color: var(--color-text-muted);
    font-size: 1rem;
    flex: 1;
    margin-bottom: var(--space-4);
}

.post-card-link {
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
}

/* Single post */
.single-post-header {
    background-color: var(--color-bg-section);
    border-bottom: 1px solid var(--color-border);
    padding-block: var(--space-12);
    text-align: center;
}

.single-post-featured-image {
    width: 100%;
    max-height: 480px;
    object-fit: cover;
    border-radius: var(--radius-lg);
    margin-bottom: var(--space-6);
    margin-inline: auto;
}

.single-post-title {
    margin-bottom: var(--space-4);
}

.single-post-meta {
    color: var(--color-text-muted);
    font-size: 1rem;
}

.single-post-body {
    padding-block: var(--space-12);
}

.single-post-footer {
    border-top: 1px solid var(--color-border);
    padding-block: var(--space-8);
}

/* Prose (WYSIWYG content) */
.prose {
    max-width: 720px;
    margin-inline: auto;
    font-size: 1.125rem;
    line-height: 1.75;
}

.prose h2,
.prose h3,
.prose h4 {
    margin-top: var(--space-8);
    margin-bottom: var(--space-3);
}

.prose p          { margin-bottom: var(--space-4); }
.prose ul         { list-style: disc; padding-left: var(--space-6); margin-bottom: var(--space-4); }
.prose ol         { list-style: decimal; padding-left: var(--space-6); margin-bottom: var(--space-4); }
.prose li         { margin-bottom: var(--space-2); }
.prose blockquote { border-left: 4px solid var(--color-primary); padding-left: var(--space-6); color: var(--color-text-muted); margin-block: var(--space-6); font-style: italic; }
.prose pre        { background-color: var(--color-bg-section); border: 1px solid var(--color-border); border-radius: var(--radius); padding: var(--space-4); overflow-x: auto; margin-bottom: var(--space-4); }
.prose code       { font-family: var(--font-mono); font-size: 0.9em; background-color: var(--color-bg-section); padding: 2px 5px; border-radius: 3px; }
.prose pre code   { background: none; padding: 0; }
.prose img        { border-radius: var(--radius); margin-block: var(--space-6); }
.prose a          { font-weight: 600; }

/* ── Blog index messages ──────────────────────────────────────────────────── */
.no-posts-message {
    text-align: center;
    color: var(--color-text-muted);
    font-size: 1.1875rem;
    padding-block: var(--space-16);
}

/* ── 404 page ─────────────────────────────────────────────────────────────── */
.error-page {
    text-align: center;
    padding-block: var(--space-16);
}

.error-page h1 {
    margin-bottom: var(--space-4);
}

.error-page p {
    color: var(--color-text-muted);
    margin-bottom: var(--space-8);
}

/* ── Legal content ────────────────────────────────────────────────────────── */
.legal-content {
    max-width: 720px;
    margin-inline: auto;
}

/* ═══════════════════════════════════════════════════════════════════════════
   ADMIN-SPECIFIC STYLES
   ═══════════════════════════════════════════════════════════════════════════ */

/* Login page */
.admin-login-page {
    background-color: var(--color-bg-section);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: var(--space-6);
}

.login-card {
    background-color: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.07);
}

.login-title {
    font-size: 1.25rem;
    margin-bottom: var(--space-1);
    text-align: center;
}

.login-subtitle {
    color: var(--color-text-muted);
    text-align: center;
    margin-bottom: var(--space-6);
    font-size: 1rem;
}

/* Admin-specific styles (tables, forms, Quill editor, status badges, etc.)
 * have been moved to public/assets/css/admin.css — the dedicated admin
 * stylesheet that is linked directly by admin pages. They do not belong here
 * because pages.css is loaded only on the public site. */
