:root {
    --cream: #FBFAF6;
    --cream-2: #F4F1E8;
    --ink: #0A0E27;
    --ink-2: #161B33;
    --muted: #5C6585;
    --lime: #A3D039;
    --lime-dark: #8AB72A;
    --magenta: #C660B8;
    --border: #E8E3D5;
    --surface: #FFFFFF;
    --serif: 'Fraunces', 'Times New Roman', serif;
    --sans: 'Plus Jakarta Sans', 'Segoe UI', Helvetica, Arial, sans-serif;
    --shadow-card: 0 1px 2px rgba(10, 14, 39, .04), 0 8px 24px rgba(10, 14, 39, .05);
    --shadow-hover: 0 8px 16px rgba(10, 14, 39, .07), 0 24px 48px rgba(10, 14, 39, .10);
}

html, body {
    font-family: var(--sans);
    color: var(--ink);
    background: var(--cream);
    margin: 0;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* Atmosfera: gradient mesh sutil (lime + magenta) sobre o cream */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(720px 420px at 12% -5%, rgba(163, 208, 57, .16) 0%, transparent 55%),
        radial-gradient(680px 520px at 100% 8%, rgba(198, 96, 184, .10) 0%, transparent 55%),
        var(--cream);
}

h1:focus {
    outline: none;
}

a {
    color: inherit;
}

/* ============================ SHELL ============================ */
.pa-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ============================ HEADER ============================ */
.pa-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px clamp(20px, 5vw, 56px);
    background: rgba(251, 250, 246, .82);
    backdrop-filter: saturate(140%) blur(12px);
    border-bottom: 1px solid var(--border);
}

.pa-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.pa-logo-mark {
    width: 42px;
    height: 42px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--lime) 0%, var(--lime-dark) 100%);
    color: var(--ink);
    font-family: var(--serif);
    font-weight: 700;
    font-size: 1.4rem;
    line-height: 1;
    box-shadow: 0 6px 16px rgba(138, 183, 42, .38);
}

.pa-brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
}

.pa-brand-word {
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: -.2px;
    color: var(--ink);
}

    .pa-brand-word em {
        font-family: var(--serif);
        font-style: italic;
        font-weight: 600;
        color: var(--lime-dark);
    }

.pa-brand-sub {
    font-size: .62rem;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--muted);
    margin-top: 3px;
}

.pa-header-spacer {
    flex: 1 1 auto;
}

.pa-header-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    text-decoration: none;
    color: var(--ink);
    font-weight: 600;
    font-size: .86rem;
    padding: 9px 16px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    transition: border-color .15s ease, transform .15s ease;
}

    .pa-header-link:hover {
        border-color: var(--lime);
        transform: translateY(-1px);
    }

/* ============================ MAIN ============================ */
.pa-main {
    flex: 1 1 auto;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(20px, 5vw, 56px);
}

/* ---- Eyebrow (rótulo small-caps com traço lime) ---- */
.pa-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--muted);
}

    .pa-eyebrow::before {
        content: "";
        width: 26px;
        height: 2px;
        background: var(--lime-dark);
        border-radius: 2px;
    }

/* ============================ HERO ============================ */
.pa-hero {
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    gap: 40px;
    align-items: center;
    padding: clamp(40px, 6vw, 76px) 0 clamp(28px, 4vw, 48px);
}

.pa-hero-title {
    font-family: var(--serif);
    font-weight: 600;
    font-size: clamp(2.4rem, 5vw, 3.6rem);
    line-height: 1.04;
    letter-spacing: -.02em;
    color: var(--ink);
    margin: 18px 0 0;
}

    .pa-hero-title em {
        font-style: italic;
        color: var(--lime-dark);
    }

.pa-hero-sub {
    font-size: 1.06rem;
    line-height: 1.55;
    color: var(--muted);
    margin: 18px 0 0;
    max-width: 30em;
}

.pa-hero-search {
    position: relative;
    margin-top: 28px;
    max-width: 440px;
}

    .pa-hero-search .pa-search-icon {
        position: absolute;
        left: 18px;
        top: 50%;
        transform: translateY(-50%);
        color: var(--muted);
        pointer-events: none;
    }

.pa-search {
    width: 100%;
    box-sizing: border-box;
    padding: 15px 18px 15px 50px;
    font-family: var(--sans);
    font-size: 1rem;
    color: var(--ink);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}

    .pa-search::placeholder {
        color: #9AA0B4;
    }

    .pa-search:focus {
        border-color: var(--lime);
        box-shadow: 0 0 0 4px rgba(163, 208, 57, .18);
    }

/* ---- Spotlight (painel navy com mascote, ecoa o login do admin) ---- */
.pa-spotlight {
    position: relative;
    border-radius: 28px;
    min-height: 340px;
    overflow: hidden;
    background:
        radial-gradient(420px 300px at 22% 18%, rgba(163, 208, 57, .22) 0%, transparent 60%),
        radial-gradient(420px 360px at 88% 92%, rgba(198, 96, 184, .22) 0%, transparent 60%),
        linear-gradient(150deg, #11173a 0%, #0A0E27 60%, #060914 100%);
    box-shadow: 0 30px 60px rgba(10, 14, 39, .28);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 28px;
}

    .pa-spotlight::after {
        /* textura de grão sutil */
        content: "";
        position: absolute;
        inset: 0;
        opacity: .5;
        background-image: radial-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px);
        background-size: 4px 4px;
        pointer-events: none;
    }

.pa-spotlight-img {
    position: absolute;
    top: 20px;
    right: 22px;
    width: 50%;
    max-width: 250px;
    height: auto;
    filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .5));
    z-index: 1;
}

.pa-spotlight-cap {
    position: relative;
    z-index: 2;
}

    .pa-spotlight-cap .pa-eyebrow {
        color: rgba(255, 255, 255, .7);
    }

    .pa-spotlight-cap .pa-eyebrow::before {
        background: var(--lime);
    }

.pa-spotlight-tag {
    font-family: var(--serif);
    font-size: 1.55rem;
    line-height: 1.15;
    color: #fff;
    margin: 12px 0 0;
}

    .pa-spotlight-tag em {
        font-style: italic;
        color: var(--lime);
    }

/* ============================ CATEGORIAS ============================ */
.pa-cat-header {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin: 14px 0 20px;
}

.pa-cat-title {
    font-family: var(--serif);
    font-weight: 600;
    font-size: clamp(1.5rem, 2.6vw, 2rem);
    color: var(--ink);
    letter-spacing: -.01em;
    margin: 0;
}

.pa-cat-count {
    font-size: .78rem;
    font-weight: 700;
    color: var(--muted);
    background: var(--cream-2);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 2px 10px;
}

.pa-cat-rule {
    flex: 1 1 auto;
    height: 1px;
    background: linear-gradient(90deg, var(--border), transparent);
}

.pa-section {
    margin-bottom: clamp(36px, 5vw, 56px);
}

/* ============================ GRID + CARDS ============================ */
.pa-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.pa-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 22px;
    box-shadow: var(--shadow-card);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

    .pa-card::before {
        content: "";
        position: absolute;
        left: 0;
        top: 22px;
        bottom: 22px;
        width: 3px;
        border-radius: 0 3px 3px 0;
        background: var(--lime);
        opacity: 0;
        transition: opacity .18s ease;
    }

    .pa-card:hover {
        transform: translateY(-4px);
        box-shadow: var(--shadow-hover);
        border-color: #DAD3BE;
    }

        .pa-card:hover::before {
            opacity: 1;
        }

.pa-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 16px;
}

.pa-card-icon {
    width: 50px;
    height: 50px;
    border-radius: 15px;
    display: grid;
    place-items: center;
    color: #fff;
    background: linear-gradient(150deg, var(--ink-2) 0%, var(--ink) 100%);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
}

    .pa-card-icon .mud-icon-root {
        font-size: 1.55rem;
        color: #fff;
    }

.pa-card-title {
    font-family: var(--serif);
    font-weight: 600;
    font-size: 1.22rem;
    color: var(--ink);
    margin: 0 0 7px;
    letter-spacing: -.01em;
}

.pa-card-desc {
    font-size: .9rem;
    line-height: 1.5;
    color: var(--muted);
    margin: 0;
    flex: 1 1 auto;
}

.pa-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.pa-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px dashed var(--border);
}

/* ---- Chips ---- */
.pa-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .02em;
    padding: 4px 11px;
    border-radius: 999px;
    white-space: nowrap;
}

.pa-chip-stack {
    color: var(--muted);
    background: var(--cream-2);
    border: 1px solid var(--border);
    text-transform: none;
    letter-spacing: 0;
    font-weight: 600;
}

.pa-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
    padding: 5px 11px;
    border-radius: 999px;
}

    .pa-status .pa-dot {
        width: 7px;
        height: 7px;
        border-radius: 50%;
        background: currentColor;
    }

.pa-status-no-ar {
    color: #4d6b0e;
    background: rgba(163, 208, 57, .20);
}

.pa-status-em-breve {
    color: #9a6a13;
    background: rgba(217, 150, 43, .16);
}

.pa-status-desktop {
    color: #2c3550;
    background: rgba(10, 14, 39, .07);
}

.pa-status-servico {
    color: #8a3b80;
    background: rgba(198, 96, 184, .14);
}

/* ---- Botoes de link ---- */
.pa-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-family: var(--sans);
    font-size: .85rem;
    font-weight: 700;
    text-decoration: none;
    padding: 9px 16px;
    border-radius: 11px;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

    .pa-btn .mud-icon-root {
        font-size: 1.05rem;
    }

.pa-btn-primary {
    color: var(--ink);
    background: linear-gradient(135deg, var(--lime) 0%, var(--lime-dark) 100%);
    box-shadow: 0 4px 12px rgba(138, 183, 42, .30);
}

    .pa-btn-primary:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 18px rgba(138, 183, 42, .42);
    }

.pa-btn-ghost {
    color: var(--ink);
    background: var(--surface);
    border: 1px solid var(--border);
}

    .pa-btn-ghost:hover {
        border-color: var(--ink);
        transform: translateY(-2px);
    }

.pa-card-nolink {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #9AA0B4;
    font-size: .82rem;
    font-style: italic;
}

/* ---- Estado vazio (busca sem resultado) ---- */
.pa-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--muted);
}

    .pa-empty .pa-empty-title {
        font-family: var(--serif);
        font-size: 1.5rem;
        color: var(--ink);
        margin: 12px 0 6px;
    }

/* ============================ FOOTER ============================ */
.pa-footer {
    margin-top: 48px;
    background: linear-gradient(150deg, #11173a 0%, #0A0E27 70%);
    color: rgba(255, 255, 255, .75);
}

.pa-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px clamp(20px, 5vw, 56px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.pa-footer-tag {
    font-family: var(--serif);
    font-size: 1.25rem;
    color: #fff;
}

    .pa-footer-tag em {
        font-style: italic;
        color: var(--lime);
    }

.pa-footer-meta {
    font-size: .78rem;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .55);
}

/* ============================ ANIMACAO DE ENTRADA ============================ */
@keyframes pa-rise {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pa-anim {
    opacity: 0;
    animation: pa-rise .5s cubic-bezier(.2, .7, .2, 1) forwards;
}

/* ============================ RESPONSIVO ============================ */
@media (max-width: 880px) {
    .pa-hero {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .pa-spotlight {
        min-height: 260px;
        order: -1;
    }

    .pa-brand-sub {
        display: none;
    }
}

@media (max-width: 560px) {
    .pa-header-link {
        display: none;
    }

    .pa-spotlight-img {
        width: 42%;
        max-width: 180px;
        top: 16px;
        right: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pa-anim {
        opacity: 1;
        animation: none;
    }
}

/* ============================ BLAZOR ERROR UI ============================ */
#blazor-error-ui {
    color-scheme: light only;
    background: #fff3cd;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: #b32121;
    padding: 1rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "Ocorreu um erro.";
    }
