:root {
  --green: #046353;
  --green-2: #007a5e;
  --teal: #009681;
  --teal-2: #0b9287;
  --mint: #98dbce;
  --deep: #003e34;
  --deep-2: #043a31;
  --amber: #eba310;
  --coral: #ef6b51;
  --violet: #6a2482;
  --ink: #1e1e1e;
  --muted: #4d5b58;
  --line: #d6e2df;
  --paper: #ffffff;
  --tint: #f1f8f6;
  --radius: 20px;
  --radius-sm: 12px;
  --shadow: 0 18px 40px -24px rgba(0, 62, 52, 0.45);
  --font: "DM Sans", "Roboto", system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
}

[hidden] { display: none !important; }
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--paper); line-height: 1.55; }
img { max-width: 100%; }
a { color: var(--green); }
h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 .5em; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
code { background: rgba(4, 99, 83, .1); padding: .1em .35em; border-radius: 6px; font-size: .92em; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--deep); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

.demo-ribbon { background: var(--deep); color: #e6f4f0; font-size: .86rem; padding: 7px 20px; text-align: center; }
.demo-ribbon p { margin: 0; }
.demo-ribbon a { color: var(--mint); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px clamp(16px, 4vw, 48px); background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand-mark { display: inline-flex; flex-direction: column; line-height: 1; }
.brand-mark small { font-size: .55rem; letter-spacing: .32em; font-weight: 700; color: var(--muted); }
.brand-mark b { font-size: 1.55rem; font-weight: 800; letter-spacing: .02em; color: #2b2f2e; }
.brand-mark em { font-style: normal; color: var(--teal); position: relative; padding-right: .3em; }
.brand-mark em::after { content: "/"; color: var(--green); margin-left: .05em; }
.brand-mark.light small, .brand-mark.light b { color: #fff; }
.brand-mark.light em { color: var(--mint); }
.brand-sub { font-weight: 600; color: var(--green); border-left: 2px solid var(--line); padding-left: 12px; }
.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a { text-decoration: none; color: var(--ink); font-weight: 500; padding: 8px 12px; border-radius: 999px; }
.site-nav a:hover { background: var(--tint); }
.site-nav .nav-portal { color: var(--green); font-weight: 700; }
.site-nav a.button { color: #fff; }
.nav-toggle { display: none; }

/* Buttons */
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 2px solid var(--green); background: var(--green); color: #fff; font: inherit; font-weight: 700; padding: 12px 22px; border-radius: 999px; text-decoration: none; cursor: pointer; transition: transform .15s, background .15s; }
.button:hover { background: var(--deep); border-color: var(--deep); transform: translateY(-1px); }
.button:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.button-small { padding: 8px 16px; font-size: .92rem; }
.button-outline { background: transparent; color: var(--green); }
.button-outline:hover { background: var(--tint); color: var(--deep); }
.button-ghost { background: transparent; border-color: transparent; color: var(--green); text-decoration: underline; text-underline-offset: 4px; }
.button-ghost:hover { background: var(--tint); border-color: var(--tint); }
.button-light { background: #fff; color: var(--deep); border-color: #fff; }
.button-light:hover { background: var(--mint); border-color: var(--mint); color: var(--deep); }
.text-link { font-weight: 700; text-decoration: none; }
.text-button { background: none; border: 0; color: var(--muted); font: inherit; font-size: .82rem; text-decoration: underline; cursor: pointer; padding: 6px 0; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 6px 12px; font: inherit; font-size: .85rem; cursor: pointer; color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--green); color: #fff; border-color: var(--green); }

.eyebrow { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--teal); margin-bottom: 10px; }

/* Hero */
.hero { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(300px, .75fr); gap: clamp(24px, 4vw, 56px); padding: clamp(40px, 7vw, 88px) clamp(16px, 4vw, 48px); background: radial-gradient(circle at 85% 10%, rgba(152, 219, 206, .55), transparent 45%), linear-gradient(160deg, #f4fbf9 0%, #fff 55%); align-items: center; }
.hero h1 { font-size: clamp(2.3rem, 5.2vw, 4.2rem); font-weight: 800; color: var(--deep); }
.hero h1 em { font-style: normal; color: var(--teal); }
.hero-copy > p { font-size: 1.15rem; color: var(--muted); max-width: 40em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 0; }
.hero-badges li { background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: .88rem; font-weight: 600; color: var(--green); }
.hero-card { background: var(--deep); color: #fff; border-radius: 28px; padding: 26px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.hero-card::after { content: "21/"; position: absolute; right: -10px; bottom: -40px; font-size: 9rem; font-weight: 800; color: rgba(255, 255, 255, .05); pointer-events: none; }
.hero-card-head { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.hero-card-head small { color: var(--mint); font-weight: 600; }
.hero-card h2 { margin: 0; font-size: 1.4rem; }
.hero-card .text-link { color: var(--mint); }
.pulse { width: 12px; height: 12px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 0 rgba(235, 163, 16, .6); animation: pulse 2s infinite; flex: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 12px rgba(235, 163, 16, 0); } 100% { box-shadow: 0 0 0 0 rgba(235, 163, 16, 0); } }
.deadline-list { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
.deadline-list li { display: grid; gap: 2px; padding: 12px 14px; border-radius: 14px; background: rgba(255, 255, 255, .08); border-left: 4px solid var(--mint); }
.deadline-list li.en-curso { border-left-color: var(--amber); }
.deadline-list li b { font-size: .98rem; }
.deadline-list li span { font-size: .85rem; opacity: .85; }
.deadline-list .skeleton { opacity: .7; }

/* Paths */
.paths { padding: 40px clamp(16px, 4vw, 48px) 10px; }
.section-kicker { font-size: 1.4rem; color: var(--deep); }
.path-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.path-grid a { display: grid; gap: 4px; padding: 18px; border-radius: var(--radius-sm); border: 1px solid var(--line); text-decoration: none; color: var(--ink); background: #fff; transition: border-color .15s, transform .15s; }
.path-grid a:hover { border-color: var(--teal); transform: translateY(-2px); }
.path-grid span { font-weight: 800; color: var(--teal); font-size: .85rem; }
.path-grid small { color: var(--muted); }

.numbers { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin: 40px clamp(16px, 4vw, 48px); padding: 28px; border-radius: var(--radius); background: linear-gradient(120deg, var(--green), var(--teal)); color: #fff; }
.numbers b { display: block; font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 800; }
.numbers span { font-size: .92rem; opacity: .92; }
.numbers .source { grid-column: 1 / -1; margin: 0; font-size: .8rem; opacity: .85; }
.numbers .source a { color: #fff; }

/* Sections */
.section { padding: clamp(48px, 7vw, 88px) clamp(16px, 4vw, 48px); }
.section-tint { background: var(--tint); }
.section-dark { background: linear-gradient(160deg, var(--deep) 0%, var(--deep-2) 100%); color: #fff; }
.section-dark .eyebrow { color: var(--mint); }
.section-dark .section-head p { color: #cfe7e1; }
.section-head { max-width: 760px; margin-bottom: 30px; }
.section-head h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); color: var(--deep); }
.section-dark .section-head h2 { color: #fff; }
.section-head p { color: var(--muted); font-size: 1.05rem; }

/* Careers */
.career-filters { display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 12px; margin-bottom: 12px; }
label { display: grid; gap: 6px; font-weight: 600; font-size: .92rem; }
input, select { font: inherit; padding: 11px 14px; border-radius: 12px; border: 1px solid #b9cbc6; background: #fff; color: var(--ink); min-width: 0; }
input:focus, select:focus { border-color: var(--teal); }
.result-count { color: var(--muted); font-size: .9rem; }
.career-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.career-card { display: flex; flex-direction: column; gap: 10px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: box-shadow .2s; }
.career-card:hover { box-shadow: var(--shadow); }
.career-card h3 { font-size: 1.15rem; margin: 0; color: var(--deep); }
.career-head { display: flex; justify-content: space-between; align-items: center; }
.career-area { font-size: .82rem; color: var(--muted); font-weight: 600; }
.tag { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .75rem; font-weight: 700; background: var(--tint); color: var(--green); }
.tag-pregrado { background: #fdf1d9; color: #8a5d00; }
.tag-posgrado { background: #f0e5f4; color: var(--violet); }
.mode-tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 0; }
.mode-tags li { font-size: .78rem; border: 1px solid var(--mint); border-radius: 999px; padding: 2px 10px; color: var(--green); }
.career-card dl { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0; font-size: .9rem; }
.career-card dt { color: var(--muted); }
.career-card dd { margin: 0; font-weight: 600; }
.career-note { font-size: .85rem; background: #fff7e6; padding: 8px 12px; border-radius: 10px; margin: 0; }
.career-actions { margin-top: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.empty { color: var(--muted); }

/* Modes */
.mode-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.mode-grid article { background: #fff; border-radius: var(--radius); padding: 22px; border: 1px solid var(--line); }
.mode-grid ul { padding-left: 18px; color: var(--muted); font-size: .9rem; margin: 0; }
.mode-icon { display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 8px; border-radius: 14px; background: var(--green); color: #fff; font-style: normal; font-weight: 800; margin-bottom: 12px; }
.table-scroll { overflow-x: auto; }
.compare-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius-sm); overflow: hidden; }
.compare-table caption { text-align: left; font-weight: 700; padding-bottom: 10px; }
.compare-table th, .compare-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: center; }
.compare-table th[scope="row"] { text-align: left; }
.compare-table thead th { background: var(--deep); color: #fff; }

/* Calendar */
.calendar-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: center; margin-bottom: 12px; }
.segmented { display: inline-flex; flex-wrap: wrap; gap: 4px; background: var(--tint); padding: 4px; border-radius: 999px; }
.segmented button { border: 0; background: transparent; font: inherit; font-weight: 600; padding: 8px 14px; border-radius: 999px; cursor: pointer; color: var(--ink); }
.segmented button[aria-pressed="true"] { background: var(--green); color: #fff; }
.date-sim { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.date-sim label { font-size: .85rem; }
.date-sim input { padding: 7px 10px; }
.calendar-status { font-weight: 600; color: var(--green); }
.calendar-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; align-items: start; }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; max-height: 760px; overflow-y: auto; padding-right: 6px; }
.timeline-item { display: grid; grid-template-columns: 210px 1fr; gap: 16px; padding: 14px 18px; border: 1px solid var(--line); border-left: 5px solid var(--teal); border-radius: 14px; background: #fff; }
.timeline-item.en-curso { border-left-color: var(--amber); background: #fffaf0; }
.timeline-item.finalizado { border-left-color: #b8c4c1; opacity: .72; }
.tl-when { display: grid; gap: 6px; align-content: start; }
.tl-body small { color: var(--muted); font-weight: 600; }
.tl-body h3 { font-size: 1.02rem; margin: 2px 0; }
.tl-body p { margin: 0; font-size: .88rem; color: var(--muted); }
.pill { display: inline-block; width: fit-content; font-size: .74rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--tint); color: var(--green); }
.pill.en-curso { background: #fdecc8; color: #7a5200; }
.pill.finalizado { background: #e8eceb; color: #5b6664; }
.calendar-aside { position: sticky; top: 100px; background: var(--tint); border-radius: var(--radius); padding: 22px; }
.legend { list-style: none; padding: 0; display: flex; gap: 14px; flex-wrap: wrap; font-size: .88rem; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; }
.dot.en-curso { background: var(--amber); }
.dot.proximo { background: var(--teal); }
.dot.finalizado { background: #b8c4c1; }
.fine { font-size: .82rem; color: var(--muted); }

/* Signup */
.stepper { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; list-style: none; padding: 0; margin: 0 0 28px; counter-reset: step; }
.stepper li { counter-increment: step; padding: 10px; border-radius: 12px; background: rgba(255, 255, 255, .08); font-weight: 600; text-align: center; font-size: .9rem; }
.stepper li::before { content: counter(step); display: block; font-size: 1.2rem; font-weight: 800; color: var(--mint); }
.stepper li.done { background: var(--teal); }
.stepper li.done::before { content: "✓"; color: #fff; }
.signup-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 28px; align-items: start; }
.signup-form { display: grid; gap: 16px; background: rgba(255, 255, 255, .06); padding: 24px; border-radius: var(--radius); border: 1px solid rgba(255, 255, 255, .12); }
.signup-form select, .signup-form input:not([type="checkbox"]):not([type="radio"]) { border-color: transparent; }
fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; }
legend { font-weight: 600; font-size: .92rem; margin-bottom: 6px; }
.radio-row, .check-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.radio-pill, .check-pill { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; background: rgba(255, 255, 255, .1); cursor: pointer; font-weight: 500; }
.radio-pill:has(input:checked), .check-pill:has(input:checked) { background: var(--mint); color: var(--deep); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.check-line { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; }
.form-error { background: #fde3dc; color: #8b2410; padding: 10px 14px; border-radius: 10px; margin: 0; }
.signup-result { background: #fff; color: var(--ink); border-radius: var(--radius); padding: 24px; min-height: 280px; transition: opacity .2s; }
.signup-result.loading { opacity: .5; }
.signup-empty b { display: block; font-size: 1.1rem; margin-bottom: 6px; color: var(--deep); }
.signup-empty p { color: var(--muted); }
.receipt-ok { display: inline-block; background: var(--tint); color: var(--green); font-weight: 700; padding: 4px 12px; border-radius: 999px; font-size: .85rem; }
.receipt h3 { margin-top: 12px; font-size: 1.5rem; color: var(--deep); }
.receipt-ref { font-family: ui-monospace, Menlo, monospace; font-weight: 700; color: var(--green); }
.receipt dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: .92rem; }
.receipt dt { color: var(--muted); }
.receipt dd { margin: 0; font-weight: 600; }
.next-steps { padding-left: 20px; }

/* Benefits */
.benefit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.benefit-card { display: grid; gap: 8px; padding: 22px; border-radius: var(--radius); border: 1px solid var(--line); align-content: start; }
.benefit-value { font-size: 1.6rem; font-weight: 800; color: var(--teal); line-height: 1.2; }
.benefit-card h3 { font-size: 1rem; margin: 0; }
.benefit-card .button { justify-self: start; }
.benefit-card .button[aria-pressed="true"] { background: var(--green); color: #fff; }
.finance-card { background: var(--tint); border-radius: var(--radius); padding: 22px; }

/* Portal promo */
.portal-promo { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.portal-promo h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); color: var(--deep); }
.flow-steps { list-style: none; padding: 0; margin: 0 0 22px; display: grid; gap: 10px; }
.flow-steps li { display: flex; gap: 12px; align-items: center; }
.flow-steps span { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--green); color: #fff; font-weight: 800; flex: none; }
.portal-preview { border-radius: 22px; overflow: hidden; background: #fff; box-shadow: var(--shadow); border: 1px solid var(--line); }
.pp-bar { display: flex; gap: 6px; align-items: center; padding: 10px 14px; background: #e8f1ef; }
.pp-bar i { width: 10px; height: 10px; border-radius: 50%; background: #b8c4c1; }
.pp-bar span { margin-left: 10px; font-size: .8rem; color: var(--muted); }
.pp-body { padding: 22px; display: grid; gap: 12px; }
.pp-row { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; font-size: .9rem; }
.pp-progress { height: 10px; background: var(--tint); border-radius: 999px; overflow: hidden; }
.pp-progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--green)); }
.pp-card { padding: 12px; border-radius: 12px; background: var(--tint); font-weight: 600; font-size: .9rem; }
.pp-card.alt { background: #fff4dc; }

/* Services, news, guide */
.service-grid, .guide-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.guide-grid { grid-template-columns: repeat(4, 1fr); }
.service-grid article, .guide-grid article, .news-grid article { padding: 22px; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; }
.service-grid h3, .guide-grid h3, .news-grid h3 { color: var(--deep); font-size: 1.1rem; }
.service-grid p, .guide-grid p, .news-grid p { color: var(--muted); font-size: .93rem; }
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.news-grid time { font-weight: 700; color: var(--coral); font-size: .85rem; }
.disclaimer { margin-top: 24px; font-size: .88rem; color: var(--muted); border-left: 4px solid var(--amber); padding-left: 14px; }
.faq { display: grid; gap: 10px; max-width: 880px; }
.faq details { background: #fff; border-radius: 14px; padding: 16px 20px; border: 1px solid var(--line); }
.faq summary { font-weight: 700; cursor: pointer; }
.faq details p { margin: 10px 0 0; color: var(--muted); }

/* Footer */
.site-footer { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 28px; padding: 48px clamp(16px, 4vw, 48px) 100px; background: var(--deep-2); color: #d6ebe6; }
.site-footer h3 { color: #fff; font-size: 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.site-footer a { color: var(--mint); }
.footer-legal { grid-column: 1 / -1; font-size: .8rem; opacity: .75; margin: 0; }
.site-footer.compact { display: block; text-align: center; padding: 24px 16px 100px; font-size: .85rem; }

/* Chat */
.chat-launcher { position: fixed; right: 20px; bottom: 20px; z-index: 60; display: inline-flex; align-items: center; gap: 10px; border: 0; background: var(--green); color: #fff; font: inherit; font-weight: 700; padding: 12px 20px 12px 12px; border-radius: 999px; box-shadow: var(--shadow); cursor: pointer; }
.chat-launcher span { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #fff; color: var(--green); font-weight: 800; }
.chat-panel { position: fixed; right: 20px; bottom: 86px; z-index: 70; width: min(615px, calc(100vw - 24px)); max-width: calc(100vw - 24px); max-height: calc(100vh - 110px); height: min(680px, calc(100vh - 110px)); min-width: 320px; min-height: 360px; display: flex; flex-direction: column; background: #fff; border-radius: 22px; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .4); border: 1px solid var(--line); overflow: hidden; }
.chat-mode { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 16px 10px 40px; background: var(--tint); font-size: .82rem; font-weight: 600; }
.segmented.small { padding: 3px; background: #fff; }
.segmented.small label { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px; cursor: pointer; font-size: .8rem; }
.segmented.small label:has(input:checked) { background: var(--green); color: #fff; }
.segmented.small input { accent-color: var(--green); margin: 0; }
.chat-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--deep); color: #fff; }
.chat-head > div { display: flex; gap: 10px; align-items: center; }
.chat-head h2 { margin: 0; font-size: 1.05rem; }
.chat-head small { color: var(--mint); }
.chat-avatar { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--teal); color: #fff; font-weight: 800; flex: none; }
.chat-avatar.big { width: 56px; height: 56px; font-size: 1.3rem; border-radius: 18px; }
.close-button { border: 0; background: rgba(255, 255, 255, .15); color: #fff; width: 34px; height: 34px; border-radius: 50%; font-size: 1.3rem; cursor: pointer; }
.chat-note { font-size: .78rem; color: var(--muted); padding: 10px 16px 0; margin: 0; }
.chat-log { flex: 1; min-height: 0; overflow-y: auto; padding: 12px 16px; display: grid; gap: 10px; align-content: start; }
.chat-msg { max-width: 88%; padding: 10px 14px; border-radius: 16px; font-size: .92rem; white-space: pre-wrap; }
.chat-msg p { margin: 0; }
.chat-msg small { display: block; margin-top: 6px; font-size: .72rem; opacity: .7; }
.chat-msg.user { justify-self: end; background: var(--green); color: #fff; border-bottom-right-radius: 4px; }
.chat-msg.bot { background: var(--tint); border-bottom-left-radius: 4px; }
.chat-msg.pending { opacity: .7; font-style: italic; }
.chat-msg.error { background: #fde3dc; color: #8b2410; }
.chat-msg.blocked { background: #f0e5f4; color: var(--violet); border: 1px solid var(--violet); }
.chat-prompts { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 16px 8px; max-height: 84px; overflow-y: auto; }
.chat-prompts button { flex: none; border: 1px solid var(--mint); background: #fff; color: var(--green); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: .8rem; cursor: pointer; }
.chat-form { display: flex; gap: 8px; padding: 10px 16px; border-top: 1px solid var(--line); }
.chat-form input { flex: 1; }
#chat-corpus { padding: 0 16px 12px; text-align: left; }

/* Portal */
.portal-main { padding: 32px clamp(16px, 4vw, 48px) 60px; min-height: 70vh; background: var(--tint); }
.portal-loading { display: grid; place-items: center; gap: 12px; padding: 80px 0; color: var(--muted); }
.loading-ring { width: 42px; height: 42px; border-radius: 50%; border: 4px solid var(--mint); border-top-color: var(--green); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.portal-login { display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center; max-width: 1100px; margin: 30px auto; }
.portal-login h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); color: var(--deep); }
.portal-login h1 em { font-style: normal; color: var(--teal); }
.login-card { background: #fff; border-radius: 26px; padding: 30px; box-shadow: var(--shadow); display: grid; gap: 14px; justify-items: start; }
.login-status { background: #fff4dc; padding: 10px 14px; border-radius: 12px; margin: 0; }
.dash-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px; align-items: flex-end; margin-bottom: 18px; }
.dash-top h1 { font-size: clamp(1.8rem, 3.8vw, 2.6rem); color: var(--deep); margin: 0; }
.dash-top p { margin: 4px 0 0; color: var(--muted); }
.toast { padding: 12px 16px; border-radius: 12px; background: #dff3ec; color: var(--deep); font-weight: 600; margin: 0 0 16px; border: 1px solid var(--mint); }
.toast.error { background: #fde3dc; color: #8b2410; border-color: #f3b6a7; }
.dash-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card { background: #fff; border-radius: var(--radius); padding: 22px; border: 1px solid var(--line); min-width: 0; }
.card.wide { grid-column: span 3; }
.card h2 { font-size: 1.2rem; color: var(--deep); }
.card-label { font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--teal); margin-bottom: 8px; }
.claims { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; font-size: .88rem; margin: 0; }
.claims dt { color: var(--muted); }
.claims dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.progress { height: 12px; background: var(--tint); border-radius: 999px; overflow: hidden; margin: 10px 0; }
.progress i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--teal), var(--green)); transition: width .6s; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 12px 0; }
.stats dt { font-size: .78rem; color: var(--muted); }
.stats dd { margin: 0; font-weight: 800; font-size: 1.1rem; color: var(--deep); }
.deadlines-card .deadline-list li { background: var(--tint); color: var(--ink); border-left-color: var(--teal); }
.deadlines-card .deadline-list li.en-curso { border-left-color: var(--amber); background: #fffaf0; }
.offer-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.offer { border: 1px solid var(--line); border-radius: 16px; padding: 16px; display: grid; gap: 12px; align-content: start; }
.offer.registered { border-color: var(--teal); background: #f4fbf9; }
.offer-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.offer-head h3 { font-size: 1rem; margin: 0; }
.slot-group { display: grid; gap: 8px; }
.slot { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; font-weight: 500; }
.slot:has(input:checked) { border-color: var(--green); background: #e8f5f1; }
.slot.disabled { opacity: .55; cursor: not-allowed; }
.slot input { margin-top: 4px; accent-color: var(--green); }
.slot span { display: grid; }
.slot b { font-size: .92rem; }
.slot b::first-letter, .mine-list span::first-letter { text-transform: uppercase; }
.slot small { color: var(--muted); font-size: .8rem; }
.offer-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.ref { font-family: ui-monospace, Menlo, monospace; color: var(--green); font-weight: 700; }
.mine-list, .subject-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.mine-list li, .subject-list li { display: grid; gap: 2px; padding: 10px 12px; border-radius: 12px; background: var(--tint); }
.mine-list span, .subject-list span { font-size: .85rem; color: var(--muted); text-transform: none; }
.mine-list small { font-family: ui-monospace, Menlo, monospace; color: var(--green); font-weight: 700; }
.mine-list .empty { background: transparent; padding: 0; }
.assistant-card { background: linear-gradient(150deg, var(--green), var(--deep)); color: #fff; display: grid; gap: 10px; align-content: start; }
.assistant-card h2 { color: #fff; }
.assistant-card .button { justify-self: start; }

/* Responsive */
@media (max-width: 1100px) {
  .path-grid { grid-template-columns: repeat(3, 1fr); }
  .mode-grid, .guide-grid { grid-template-columns: repeat(2, 1fr); }
  .numbers { grid-template-columns: repeat(3, 1fr); }
  .calendar-layout, .signup-layout, .portal-promo { grid-template-columns: 1fr; }
  .calendar-aside { position: static; }
  .dash-grid { grid-template-columns: repeat(2, 1fr); }
  .card.wide { grid-column: span 2; }
}
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 8px 16px; font: inherit; font-weight: 600; cursor: pointer; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; background: #fff; padding: 12px 16px 18px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .site-nav.open { display: flex; }
  .portal-nav { display: flex; position: static; flex-direction: row; padding: 0; box-shadow: none; border: 0; background: transparent; }
  .hero { grid-template-columns: 1fr; }
  .career-filters { grid-template-columns: 1fr 1fr; }
  .service-grid, .news-grid, .benefit-grid { grid-template-columns: 1fr 1fr; }
  .site-footer { grid-template-columns: 1fr; }
  .stepper { grid-template-columns: repeat(3, 1fr); }
  .portal-login { grid-template-columns: 1fr; }
  .brand-sub { display: none; }
}
@media (max-width: 600px) {
  .path-grid, .mode-grid, .guide-grid, .service-grid, .news-grid, .benefit-grid, .career-filters, .two-col { grid-template-columns: 1fr; }
  .numbers { grid-template-columns: 1fr 1fr; }
  .timeline-item { grid-template-columns: 1fr; gap: 6px; }
  .dash-grid { grid-template-columns: 1fr; }
  .card.wide { grid-column: auto; }
  .chat-panel { right: 12px; bottom: 80px; width: calc(100vw - 24px) !important; height: min(640px, calc(100vh - 100px)) !important; min-width: 0; }
  .chat-launcher { right: 12px; bottom: 12px; }
  .hero-actions .button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
.pp-progress i.w57 { width: 57%; }
.check-line.inline { font-size: .88rem; font-weight: 600; align-items: center; }

.chat-resize { position: absolute; top: 7px; left: 7px; z-index: 2; width: 24px; height: 24px; padding: 0; border: 1px solid var(--mint); border-radius: 8px; background: #fff; cursor: nwse-resize; touch-action: none; display: grid; place-items: center; color: var(--green); }
.chat-resize:hover, .chat-resize:focus-visible { background: var(--mint); }
.chat-resize svg { width: 14px; height: 14px; }
.chat-panel.resizing { user-select: none; }
.chat-msg { max-width: 92%; }
@media (max-width: 600px) { .chat-resize { display: none; } }
