/* =============================================
   Hub - Estudos de Mercado Educacional 2026
   ============================================= */

.emb {
    --emb-primary: #083FCF;
    --emb-primary-deep: #071747;
    --emb-secondary: #FC7D55;
    --emb-tertiary: #B073FF;
    --emb-text: #1F2937;
    --emb-text-light: #6B7280;
    --emb-border: #E5E7EB;
    --emb-surface: #F8FAFC;
    --emb-heading: 'Outfit', sans-serif;
    --emb-body: 'Nunito', sans-serif;

    font-family: var(--emb-body);
    color: var(--emb-text);
    line-height: 1.6;
}

.emb *,
.emb *::before,
.emb *::after {
    box-sizing: border-box;
}

:where(.emb) h1,
:where(.emb) h2,
:where(.emb) h3,
:where(.emb) h4 {
    margin: 0;
    font-family: var(--emb-heading);
    line-height: 1.15;
}

:where(.emb) p {
    margin: 0;
}

:where(.emb) a {
    color: inherit;
    text-decoration: none;
}

.emb-container {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.emb-eyebrow {
    display: inline-block;
    color: var(--emb-secondary);
    font-family: var(--emb-heading);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.emb-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    font-family: var(--emb-heading);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.emb-btn svg {
    flex-shrink: 0;
}

.emb-btn--cta {
    min-height: 56px;
    padding: 0 1.9rem;
    color: #ffffff;
    background: var(--emb-secondary);
    box-shadow: 0 10px 26px rgba(252, 125, 85, 0.42);
}

.emb-btn--cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 32px rgba(252, 125, 85, 0.5);
}

.emb-btn--cta:disabled {
    cursor: not-allowed;
    opacity: 0.7;
    transform: none;
}

.emb-btn--full {
    width: 100%;
}

.emb-btn--ghost {
    min-height: 48px;
    padding: 0 1.4rem;
    border: 1.5px solid var(--emb-border);
    color: var(--emb-primary);
    background: #ffffff;
}

.emb-btn--ghost:hover {
    border-color: var(--emb-primary);
    background: var(--emb-primary);
    color: #ffffff;
}

/* ---------- Hero ---------- */
.emb-hero {
    position: relative;
    padding: 8rem 0 7.5rem;
    overflow: hidden;
    background:
        radial-gradient(circle at 14% 16%, rgba(176, 115, 255, 0.3) 0%, transparent 32%),
        radial-gradient(circle at 86% 78%, rgba(252, 125, 85, 0.24) 0%, transparent 36%),
        linear-gradient(135deg, var(--emb-primary-deep) 0%, var(--emb-primary) 56%, #5b55df 100%);
}

.emb-hero__dots {
    position: absolute;
    inset: 0;
    opacity: 0.07;
    background-image: radial-gradient(circle at 1px 1px, #fff 1px, transparent 0);
    background-size: 32px 32px;
    pointer-events: none;
}

.emb-hero__map {
    position: absolute;
    top: 50%;
    left: 50%;
    width: min(85%, 720px);
    opacity: 0.13;
    transform: translate(-50%, -50%);
    pointer-events: none;
    user-select: none;
}

.emb-hero__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 6rem;
}

.emb-hero__copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.75rem;
}

.emb-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.6rem 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
    font-family: var(--emb-heading);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.emb-badge svg {
    color: var(--emb-secondary);
}

/* As margens negativas descontam a meia-entrelinha de cada bloco de texto,
   para que o gap de 1.75rem do .emb-hero__copy seja o espaco visto na tela. */
.emb-hero__title {
    max-width: 18ch;
    margin-block: -0.1em;
    color: #ffffff;
    font-size: clamp(2.1rem, 4.4vw, 3.15rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.emb-hero__title span {
    color: var(--emb-secondary);
}

.emb-hero__subtitle {
    max-width: 38rem;
    margin-block: -0.4em;
    color: #DDE7FF;
    font-size: 1.08rem;
    line-height: 1.8;
}

.emb-hero__subtitle strong {
    color: #ffffff;
    font-weight: 800;
}

.emb-hero__actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
}

.emb-hero__note {
    max-width: 22rem;
    color: rgba(221, 231, 255, 0.78);
    font-size: 0.9rem;
    line-height: 1.55;
}

/* Card Destaques nacionais */
.emb-highlights {
    padding: 2.6rem 2.4rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.24);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.emb-highlights__title {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 2.15rem;
    padding-bottom: 1.35rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.16);
    color: #ffffff;
    font-size: 1.05rem;
    font-weight: 700;
}

.emb-highlights__title svg {
    color: var(--emb-secondary);
}

.emb-highlights__list {
    display: flex;
    flex-direction: column;
    gap: 2.15rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.emb-highlights__list li {
    display: flex;
    align-items: flex-start;
    gap: 1.15rem;
}

.emb-highlights__icon {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: var(--emb-secondary);
    background: rgba(255, 255, 255, 0.1);
}

.emb-highlights__list strong {
    display: block;
    margin-bottom: 0.3rem;
    color: #ffffff;
    font-family: var(--emb-heading);
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1.35;
}

.emb-highlights__list span {
    color: #DDE7FF;
    font-size: 0.88rem;
    line-height: 1.55;
}

/* ---------- Secoes claras ---------- */
.emb-section {
    padding: 5.5rem 0;
}

.emb-section--white {
    background: #ffffff;
    border-bottom: 1px solid var(--emb-border);
}

.emb-section--soft {
    background: var(--emb-surface);
}

.emb-section__header {
    max-width: 46rem;
    margin-bottom: 3rem;
}

.emb-section__header--center {
    margin-right: auto;
    margin-left: auto;
    text-align: center;
}

.emb-section__header h2 {
    margin: 0.75rem 0 1rem;
    color: var(--emb-primary);
    font-size: clamp(1.75rem, 3.4vw, 2.35rem);
    font-weight: 800;
    line-height: 1.18;
}

.emb-section__header p {
    color: var(--emb-text-light);
    font-size: 1.05rem;
    line-height: 1.7;
}

/* ---------- O que os dados revelam ---------- */
.emb-insights {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.emb-insight {
    display: flex;
    flex-direction: column;
    padding: 1.75rem;
    border: 1px solid var(--emb-border);
    border-radius: 18px;
    background: var(--emb-surface);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.emb-insight:hover {
    transform: translateY(-4px);
    border-color: var(--emb-secondary);
    box-shadow: 0 18px 36px rgba(8, 63, 207, 0.1);
}

.emb-insight__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 1.25rem;
    border-radius: 12px;
    background: #DDE7FF;
    color: var(--emb-primary);
}

.emb-insight__icon--warm {
    background: #FFE4DC;
    color: var(--emb-secondary);
}

.emb-insight__icon--violet {
    background: #EFE2FF;
    color: var(--emb-tertiary);
}

.emb-insight__num {
    margin-bottom: 0.5rem;
    color: rgba(252, 125, 85, 0.75);
    font-family: var(--emb-heading);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
}

.emb-insight h3 {
    margin-bottom: 0.6rem;
    color: var(--emb-text);
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.35;
}

.emb-insight p {
    color: var(--emb-text-light);
    font-size: 0.9rem;
    line-height: 1.65;
}

/* ---------- Escolha por regiao ---------- */
/* Flex em vez de grid para que a ultima linha, com 2 dos 5 cards, fique centralizada. */
.emb-regions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

.emb-region {
    position: relative;
    display: flex;
    flex-direction: column;
    width: calc(33.333% - 1rem);
    padding: 1.85rem;
    overflow: hidden;
    border: 1px solid var(--emb-border);
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.emb-region:hover {
    transform: translateY(-4px);
    border-color: var(--emb-primary);
    box-shadow: 0 20px 40px rgba(8, 63, 207, 0.12);
}

.emb-region::after {
    content: '';
    position: absolute;
    top: -2rem;
    right: -2rem;
    width: 8rem;
    height: 8rem;
    border-bottom-left-radius: 100%;
    background: rgba(8, 63, 207, 0.05);
    pointer-events: none;
    transition: background 0.25s ease;
}

.emb-region:hover::after {
    background: rgba(8, 63, 207, 0.1);
}

.emb-region__head {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 1.35rem;
}

.emb-region__pin {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 13px;
    color: var(--emb-primary);
    background: #DDE7FF;
}

.emb-region__head h3 {
    color: var(--emb-primary);
    font-size: 1.25rem;
    font-weight: 800;
}

.emb-region__ufs {
    color: var(--emb-text-light);
    font-family: var(--emb-heading);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.emb-region__stats {
    position: relative;
    z-index: 1;
    flex-grow: 1;
    margin-bottom: 1.5rem;
}

.emb-region__stat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.7rem 0;
    border-bottom: 1px solid var(--emb-border);
}

.emb-region__stat:last-child {
    border-bottom: 0;
}

.emb-region__stat dt {
    color: var(--emb-text-light);
    font-size: 0.88rem;
}

.emb-region__stat dd {
    margin: 0;
    color: var(--emb-text);
    font-family: var(--emb-heading);
    font-size: 1.1rem;
    font-weight: 800;
}

.emb-region__stat--lead dd {
    color: var(--emb-secondary);
}

.emb-region .emb-btn {
    position: relative;
    z-index: 1;
    min-height: 48px;
    width: 100%;
}

/* ---------- Origem dos dados ---------- */
.emb-sources {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.emb-source {
    min-height: 290px;
    padding: 2rem;
    border-radius: 22px;
    color: #ffffff;
    box-shadow: 0 18px 42px rgba(8, 63, 207, 0.14);
}

.emb-source--pnae {
    background: linear-gradient(135deg, #2443df 0%, #4837d8 100%);
}

.emb-source--radar {
    background: linear-gradient(135deg, #7c3aed 0%, #a95cff 100%);
}

.emb-source__eyebrow {
    display: inline-flex;
    margin-bottom: 0.85rem;
    color: rgba(255, 255, 255, 0.72);
    font-family: var(--emb-heading);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.emb-source h3 {
    margin-bottom: 1rem;
    color: #ffffff;
    font-size: clamp(1.5rem, 3vw, 1.95rem);
    font-weight: 800;
}

.emb-source p {
    max-width: 520px;
    color: rgba(255, 255, 255, 0.84);
    line-height: 1.7;
}

/* ---------- Formulario ---------- */
.emb-form-section {
    padding: 5.5rem 0;
    background:
        radial-gradient(circle at 18% 22%, rgba(252, 125, 85, 0.18), transparent 30%),
        linear-gradient(145deg, var(--emb-primary-deep) 0%, var(--emb-primary) 58%, #5736c7 100%);
}

.emb-form-grid {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    align-items: start;
    gap: 3.5rem;
}

.emb-form-pitch h2 {
    margin: 0.75rem 0 1rem;
    color: #ffffff;
    font-size: clamp(1.75rem, 3.4vw, 2.3rem);
    font-weight: 800;
}

.emb-form-pitch > p {
    margin-bottom: 2rem;
    color: #DDE7FF;
    font-size: 1.05rem;
    line-height: 1.7;
}

.emb-form-pitch ul {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.emb-form-pitch li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    color: #ffffff;
    font-size: 1rem;
}

.emb-form-pitch li svg {
    flex-shrink: 0;
    margin-top: 0.2rem;
    color: var(--emb-secondary);
}

.emb-form-card {
    padding: 2.25rem;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.22);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Chip de regiao detectada */
.emb-region-chip {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 1.5rem;
    padding: 0.85rem 1.1rem;
    border: 1px dashed rgba(255, 255, 255, 0.3);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.07);
    color: #DDE7FF;
    font-size: 0.9rem;
}

.emb-region-chip svg {
    flex-shrink: 0;
    color: var(--emb-secondary);
}

.emb-region-chip strong {
    color: #ffffff;
    font-family: var(--emb-heading);
    font-weight: 800;
}

.emb-region-chip[data-state="selected"] {
    border-style: solid;
    border-color: rgba(252, 125, 85, 0.55);
    background: rgba(252, 125, 85, 0.12);
}

.emb-fields {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.emb-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.emb-field--wide {
    grid-column: 1 / -1;
}

.emb-field label {
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.88rem;
    font-weight: 800;
}

.emb-field label span {
    color: #ffb394;
}

.emb-field input,
.emb-field select {
    width: 100%;
    height: 50px;
    padding: 0 1rem;
    border: 1.5px solid rgba(255, 255, 255, 0.24);
    border-radius: 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.13);
    font-family: var(--emb-body);
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
}

.emb-field select {
    padding-right: 2.6rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23ffffff' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.emb-field select option {
    color: #ffffff;
    background: #26318f;
}

.emb-field input::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

.emb-field input:focus,
.emb-field select:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.68);
    background: rgba(255, 255, 255, 0.18);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.12);
}

.emb-field .emb-invalid {
    border-color: #ff8a8a;
    box-shadow: 0 0 0 3px rgba(255, 138, 138, 0.16);
}

.emb-error {
    color: #ffd0d0;
    font-size: 0.78rem;
}

.emb-form-card .emb-btn--cta {
    margin-top: 0.4rem;
}

.emb-disclaimer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 1.1rem;
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.8rem;
    text-align: center;
}

.emb-disclaimer svg {
    flex-shrink: 0;
}

/* ---------- Modal de confirmacao ---------- */
.emb-modal[hidden] {
    display: none;
}

.emb-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(7, 23, 71, 0.72);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: emb-fade 0.2s ease;
}

@keyframes emb-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

.emb-modal__dialog {
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    padding: 2.25rem;
    overflow-y: auto;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.3);
    animation: emb-rise 0.25s ease;
}

@keyframes emb-rise {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.emb-modal__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 1.25rem;
    border-radius: 15px;
    color: var(--emb-primary);
    background: #DDE7FF;
}

.emb-modal__dialog h2 {
    margin-bottom: 0.7rem;
    color: var(--emb-primary);
    font-size: 1.5rem;
    font-weight: 800;
}

.emb-modal__lead {
    margin-bottom: 1.5rem;
    color: var(--emb-text-light);
    line-height: 1.65;
}

.emb-modal__lead strong {
    color: var(--emb-text);
}

.emb-modal__actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.emb-modal__switch {
    width: 100%;
    padding: 0;
    border: 0;
    color: var(--emb-text-light);
    background: none;
    cursor: pointer;
    font-family: var(--emb-body);
    font-size: 0.9rem;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.emb-modal__switch:hover {
    color: var(--emb-primary);
}

.emb-modal__options {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-bottom: 1.25rem;
}

.emb-modal__options[hidden] {
    display: none;
}

.emb-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: 100%;
    padding: 0.95rem 1.1rem;
    border: 1.5px solid var(--emb-border);
    border-radius: 14px;
    background: #ffffff;
    cursor: pointer;
    font-family: var(--emb-body);
    text-align: left;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.emb-option:hover {
    border-color: var(--emb-primary);
    background: var(--emb-surface);
}

.emb-option[aria-pressed="true"] {
    border-color: var(--emb-primary);
    background: #DDE7FF;
}

.emb-option__body {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.emb-option strong {
    color: var(--emb-text);
    font-family: var(--emb-heading);
    font-size: 1rem;
    font-weight: 800;
}

.emb-option__meta {
    color: var(--emb-text-light);
    font-size: 0.8rem;
}

.emb-option em {
    flex-shrink: 0;
    color: var(--emb-primary);
    font-size: 0.78rem;
    font-style: normal;
    font-weight: 700;
}

/* ---------- Responsivo ---------- */
@media (max-width: 1024px) {
    .emb-insights {
        grid-template-columns: repeat(2, 1fr);
    }

    .emb-region {
        width: calc(50% - 0.75rem);
    }
}

@media (max-width: 900px) {
    .emb-hero {
        padding: 5rem 0 4.5rem;
    }

    .emb-hero__title {
        max-width: none;
    }

    .emb-hero__grid,
    .emb-form-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .emb-sources {
        grid-template-columns: 1fr;
    }

    .emb-section {
        padding: 4rem 0;
    }
}

@media (max-width: 640px) {
    .emb-container {
        padding: 0 1.15rem;
    }

    .emb-insights {
        grid-template-columns: 1fr;
    }

    .emb-region {
        width: 100%;
    }

    .emb-fields {
        grid-template-columns: 1fr;
    }

    .emb-hero__actions {
        flex-direction: column;
        align-items: stretch;
    }

    .emb-hero__note {
        max-width: none;
    }

    .emb-form-card,
    .emb-modal__dialog {
        padding: 1.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .emb *,
    .emb-modal,
    .emb-modal__dialog {
        animation: none !important;
        transition: none !important;
    }
}
