@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@700;800&display=swap');

:root {
  --purple: #681e5b;
  --purple-dark: #421039;
  --purple-soft: #f6edf4;
  --gold: #d29703;
  --ink: #1f2529;
  --muted: #69737a;
  --line: #e6e1e5;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: radial-gradient(circle at 90% 8%, rgba(210,151,3,.15), transparent 27%), linear-gradient(135deg, #faf8fa, #f1edf1);
  font-family: "DM Sans", system-ui, sans-serif;
}

.portal-shell { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 54px 0 26px; }
.portal-header { display: grid; grid-template-columns: 230px 1px 1fr; gap: 32px; align-items: center; padding: 36px 38px; color: white; border-radius: 24px; background: radial-gradient(circle at 84% 15%, rgba(210,151,3,.3), transparent 30%), linear-gradient(125deg, var(--purple-dark), var(--purple)); box-shadow: 0 22px 70px rgba(66,16,57,.2); }
.portal-header::before { content: ""; grid-column: 2; width: 1px; height: 92px; background: rgba(255,255,255,.2); }
.portal-header img { width: 100%; max-height: 92px; object-fit: contain; filter: drop-shadow(0 4px 8px rgba(0,0,0,.14)); }
.portal-header > div { grid-column: 3; }
.eyebrow { margin: 0 0 8px; color: #f1cc70; font-size: 11px; font-weight: 700; letter-spacing: .18em; }
h1 { margin: 0; font: 800 clamp(32px, 5vw, 52px)/1.05 "Manrope", sans-serif; letter-spacing: -.045em; }
.intro { max-width: 600px; margin: 14px 0 0; color: rgba(255,255,255,.75); font-size: 15px; line-height: 1.6; }

.apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 22px; }
.app-card { min-height: 270px; position: relative; display: flex; flex-direction: column; padding: 26px; color: var(--ink); background: rgba(255,255,255,.9); border: 1px solid rgba(221,212,219,.9); border-radius: 20px; box-shadow: 0 12px 40px rgba(60,36,54,.07); text-decoration: none; overflow: hidden; transition: transform .2s, box-shadow .2s, border-color .2s; }
.app-card::after { content: ""; position: absolute; right: -80px; bottom: -100px; width: 200px; height: 200px; border: 1px solid rgba(104,30,91,.1); border-radius: 50%; box-shadow: 0 0 0 35px rgba(104,30,91,.025); }
.app-card:hover { transform: translateY(-4px); border-color: #c6a9bf; box-shadow: 0 22px 55px rgba(60,36,54,.13); }
.app-card:focus-visible { outline: 3px solid rgba(210,151,3,.45); outline-offset: 3px; }
.app-card__number { position: absolute; top: 24px; right: 27px; color: #c4b9c1; font: 800 12px "Manrope", sans-serif; letter-spacing: .12em; }
.app-card__icon { width: 50px; height: 50px; display: grid; place-items: center; color: var(--purple); background: var(--purple-soft); border-radius: 14px; }
.app-card__icon svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.app-card__body { margin-top: 28px; max-width: 380px; }
.app-card__body p { margin: 0 0 7px; color: var(--gold); font-size: 10px; font-weight: 700; letter-spacing: .14em; }
.app-card__body h2 { margin: 0; color: var(--purple-dark); font: 800 22px/1.2 "Manrope", sans-serif; letter-spacing: -.025em; }
.app-card__body span { display: block; margin-top: 10px; color: var(--muted); font-size: 12px; line-height: 1.55; }
.app-card__arrow { margin-top: auto; color: var(--purple); font-size: 24px; line-height: 1; }
.app-card--events .app-card__icon { color: #176a62; background: #e8f5f2; }
.app-card--consulta { border-color: rgba(210,151,3,.35); }
.app-card--consulta .app-card__icon { color: #8b6205; background: #fff4d8; }

footer { display: flex; justify-content: space-between; padding: 24px 4px 0; color: #7a7378; font-size: 11px; }

@media (max-width: 940px) {
  .apps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .portal-shell { width: calc(100% - 28px); padding-top: 18px; }
  .portal-header { grid-template-columns: 1fr; gap: 20px; padding: 28px 24px; text-align: center; }
  .portal-header::before { display: none; }
  .portal-header img { width: 210px; justify-self: center; }
  .portal-header > div { grid-column: 1; }
  .apps { grid-template-columns: 1fr; }
  .app-card { min-height: 230px; }
  footer { flex-direction: column; gap: 5px; text-align: center; }
}
