:root {
  --bg-deep: #531d20;
  --bg-base: #7c3136;
  --bg-soft: #a84b50;
  --panel: rgba(255, 248, 240, 0.94);
  --panel-strong: rgba(255, 252, 248, 0.98);
  --ink: #2c1b1d;
  --ink-soft: #6b4b4e;
  --green: #1f5f3e;
  --green-strong: #14452d;
  --gold: #f2c66d;
  --line: rgba(83, 29, 32, 0.12);
  --shadow: 0 24px 70px rgba(34, 10, 12, 0.25);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --selection-width: min(1080px, 92vw);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

html {
  font-size: 15px;
}

body {
  margin: 0;
  font-family: "Montserrat", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.1), transparent 28%),
    radial-gradient(circle at right center, rgba(242, 198, 109, 0.15), transparent 25%),
    linear-gradient(135deg, var(--bg-deep), var(--bg-base) 55%, var(--bg-soft));
  overflow-x: hidden;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: auto;
  z-index: -1;
  border-radius: 999px;
  filter: blur(8px);
}

body::before {
  width: 420px;
  height: 420px;
  top: -110px;
  right: -120px;
  background: rgba(242, 198, 109, 0.16);
}

body::after {
  width: 360px;
  height: 360px;
  bottom: -100px;
  left: -80px;
  background: rgba(255, 255, 255, 0.08);
}

.screen {
  min-height: 100vh;
}

.hidden {
  display: none !important;
}

.selection-screen {
  display: grid;
  place-items: center;
  padding: 40px;
}

.selection-card {
  width: var(--selection-width);
  padding: clamp(32px, 4vw, 54px);
  border-radius: 36px;
  background:
    linear-gradient(135deg, rgba(255, 252, 248, 0.97), rgba(255, 244, 231, 0.94));
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.selection-card::before {
  content: "";
  position: absolute;
  width: 320px;
  height: 320px;
  top: -130px;
  right: -60px;
  border-radius: 999px;
  background: rgba(31, 95, 62, 0.11);
}

.selection-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, transparent 0 62%, rgba(83, 29, 32, 0.05) 62% 100%);
  pointer-events: none;
}

.selection-header,
.selection-actions,
.app-shell {
  position: relative;
  z-index: 1;
}

.selection-brand {
  display: flex;
  align-items: center;
  gap: 24px;
}

.selection-brand img {
  width: clamp(96px, 11vw, 160px);
  height: auto;
  filter: drop-shadow(0 10px 18px rgba(20, 69, 45, 0.2));
}

.eyebrow {
  margin: 0 0 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.92rem;
  color: var(--green);
  font-weight: 800;
}

.selection-card h1,
.panel-header h3,
.empty-state strong,
.special-caption strong {
  font-family: "Bricolage Grotesque", "Montserrat", sans-serif;
}

.selection-card h1 {
  margin: 0;
  font-size: clamp(2.4rem, 4vw, 4.2rem);
  line-height: 0.95;
}

.selection-card p {
  max-width: 780px;
  margin: 18px 0 0;
  color: var(--ink-soft);
  font-size: clamp(0.96rem, 1.55vw, 1.2rem);
}

.selection-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 22px;
  margin-top: 42px;
}

.campus-button,
.ghost-button {
  border: 0;
  cursor: pointer;
  font: inherit;
}

.campus-button {
  display: block;
  padding: 28px;
  border-radius: 26px;
  min-height: 180px;
  text-align: left;
  color: #fff;
  background:
    linear-gradient(145deg, rgba(31, 95, 62, 0.96), rgba(20, 69, 45, 0.96));
  box-shadow: 0 20px 44px rgba(20, 69, 45, 0.25);
  transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

.campus-button[data-campus="bilbao"] {
  background:
    linear-gradient(145deg, rgba(83, 29, 32, 0.96), rgba(122, 49, 54, 0.96));
  box-shadow: 0 20px 44px rgba(83, 29, 32, 0.26);
}

.campus-button::before {
  content: "";
  position: absolute;
  inset: auto -36px -36px auto;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
}

.campus-button:hover,
.campus-button:focus-visible,
.ghost-button:hover,
.ghost-button:focus-visible {
  transform: translateY(-3px);
}

.campus-button:focus-visible,
.ghost-button:focus-visible {
  outline: 3px solid rgba(242, 198, 109, 0.85);
  outline-offset: 3px;
}

.campus-button strong {
  display: block;
  font-size: clamp(1.75rem, 2.6vw, 2.6rem);
  margin-bottom: 8px;
}

.campus-button span {
  display: block;
  max-width: 300px;
  opacity: 0.88;
  line-height: 1.45;
  font-weight: 500;
  font-size: 0.94rem;
}

.selection-note {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
  padding: 12px 18px;
  border-radius: 999px;
  background: rgba(31, 95, 62, 0.08);
  color: var(--green-strong);
  font-weight: 700;
}

.selection-note::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--gold);
  box-shadow: 0 0 0 8px rgba(242, 198, 109, 0.18);
}

.app-shell {
  padding: 24px 24px 28px;
}

.app-frame {
  min-height: calc(100vh - 52px);
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  padding: 24px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #fff;
}

.brand-block img {
  width: clamp(78px, 7vw, 112px);
  height: auto;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.18));
}

.brand-copy h1 {
  margin: 4px 0 0;
  font-family: "Bricolage Grotesque", "Montserrat", sans-serif;
  font-size: clamp(1.75rem, 2.5vw, 2.8rem);
  line-height: 0.94;
}

.brand-copy p {
  margin: 0;
  opacity: 0.8;
  font-size: 0.92rem;
}

.header-actions {
  display: flex;
  align-items: stretch;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.meta-chip,
.ghost-button {
  border-radius: 18px;
}

.meta-chip {
  min-width: 200px;
  padding: 14px 18px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.meta-chip small {
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.74rem;
  opacity: 0.72;
  margin-bottom: 7px;
}

.meta-chip strong {
  display: block;
  font-size: clamp(1.02rem, 1.5vw, 1.35rem);
}

.ghost-button {
  padding: 0 20px;
  min-height: 72px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-weight: 700;
  font-size: 0.92rem;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14);
  transition: transform 0.22s ease, background 0.22s ease;
}

.campus-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.ghost-button:hover,
.ghost-button:focus-visible {
  background: rgba(255, 255, 255, 0.18);
}

.dashboard {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: 22px;
  align-items: start;
}

.dashboard.has-specials {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.special-stage {
  min-height: 268px;
  border-radius: 26px;
  overflow: hidden;
  background:
    linear-gradient(155deg, rgba(31, 95, 62, 0.88), rgba(20, 69, 45, 0.96));
  color: #fff;
  position: relative;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.special-stage::before {
  content: "";
  position: absolute;
  width: 180px;
  height: 180px;
  top: -30px;
  right: -30px;
  border-radius: 999px;
  background: rgba(242, 198, 109, 0.14);
}

.special-placeholder,
.special-slide {
  position: relative;
  z-index: 1;
  height: 100%;
}

.special-placeholder {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.14), transparent 32%);
}

.special-placeholder img {
  position: absolute;
  width: clamp(120px, 14vw, 170px);
  top: 22px;
  right: 24px;
  opacity: 0.16;
  filter: grayscale(1) brightness(4);
}

.special-placeholder strong {
  font-size: clamp(1.28rem, 1.7vw, 1.7rem);
  max-width: 320px;
}

.special-placeholder p {
  margin: 10px 0 0;
  max-width: 420px;
  font-size: 0.93rem;
  line-height: 1.45;
  opacity: 0.86;
}

.special-slide {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
}

.special-media {
  position: relative;
  min-height: 100%;
  background: rgba(0, 0, 0, 0.12);
}

.special-media img,
.special-media video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.special-caption {
  padding: 26px 24px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 14px;
  background:
    linear-gradient(180deg, rgba(12, 28, 18, 0.2), rgba(12, 28, 18, 0.36));
}

.special-caption span {
  display: inline-flex;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
  font-weight: 800;
}

.special-caption strong {
  font-size: clamp(1.35rem, 1.8vw, 1.9rem);
  line-height: 0.96;
}

.special-caption p {
  margin: 0;
  font-size: 0.93rem;
  line-height: 1.45;
  opacity: 0.86;
}

.special-dots {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

.special-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
}

.special-dot.active {
  background: var(--gold);
}

.special-panel {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
}

.special-panel .panel-header {
  margin-bottom: 0;
}

.special-panel .special-stage {
  min-height: 320px;
  height: 100%;
}

.panel {
  min-width: 0;
  border-radius: var(--radius-xl);
  padding: 24px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.panel-header h3 {
  margin: 0 0 6px;
  font-size: clamp(1.55rem, 1.9vw, 2.1rem);
  line-height: 0.95;
}

.panel-header p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.93rem;
}

.range-chip {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(31, 95, 62, 0.08);
  color: var(--green-strong);
  font-size: 0.84rem;
  font-weight: 800;
  white-space: nowrap;
}

.list {
  display: grid;
  gap: 14px;
}

.item-card,
.empty-state {
  border-radius: var(--radius-md);
  background: var(--panel-strong);
  border: 1px solid var(--line);
}

.item-card {
  padding: 18px 18px 17px;
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 16px;
  align-items: center;
}

.item-date {
  padding: 14px 10px;
  border-radius: 18px;
  text-align: center;
  color: #fff;
  background:
    linear-gradient(145deg, rgba(31, 95, 62, 0.94), rgba(20, 69, 45, 0.98));
  box-shadow: 0 12px 22px rgba(20, 69, 45, 0.18);
}

.events-panel .item-date {
  background:
    linear-gradient(145deg, rgba(83, 29, 32, 0.94), rgba(122, 49, 54, 0.98));
  box-shadow: 0 12px 22px rgba(83, 29, 32, 0.18);
}

.item-date strong {
  display: block;
  font-size: 1.28rem;
  line-height: 1;
}

.item-date span {
  display: block;
  margin-top: 8px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.66rem;
  opacity: 0.88;
}

.item-content strong {
  display: block;
  font-size: clamp(1.05rem, 1.45vw, 1.35rem);
  line-height: 1.05;
}

.item-content p {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 0.93rem;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(31, 95, 62, 0.08);
  color: var(--green-strong);
  font-size: 0.76rem;
  font-weight: 700;
}

.pill.secondary {
  background: rgba(83, 29, 32, 0.08);
  color: var(--bg-deep);
}

.empty-state {
  min-height: 180px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.empty-state strong {
  font-size: clamp(1.18rem, 1.55vw, 1.55rem);
}

.empty-state p {
  margin: 10px 0 0;
  color: var(--ink-soft);
  max-width: 560px;
  font-size: 0.93rem;
  line-height: 1.45;
}

.status-bar {
  margin-top: 18px;
  padding: 16px 18px;
  border-radius: 18px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(8px);
}

.status-bar p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.4;
}

.status-bar strong {
  font-size: 0.88rem;
  font-weight: 800;
}

.status-bar.is-error {
  background: rgba(83, 29, 32, 0.52);
}

.status-bar.is-ok {
  background: rgba(20, 69, 45, 0.42);
}

.fade-in {
  animation: fadeInUp 0.5s ease both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

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

@media (max-width: 1180px) {
  .dashboard,
  .dashboard.has-specials,
  .special-slide,
  .selection-actions {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 840px) {
  .selection-screen,
  .app-shell {
    padding: 16px;
  }

  .app-frame {
    border-radius: 24px;
    padding: 16px;
  }

  .topbar,
  .panel-header {
    flex-direction: column;
  }

  .header-actions {
    width: 100%;
    justify-content: stretch;
  }

  .meta-chip,
  .ghost-button {
    width: 100%;
  }

  .item-card {
    grid-template-columns: 1fr;
  }

  .item-date {
    width: fit-content;
    min-width: 92px;
  }
}

@media (min-width: 1600px) and (min-aspect-ratio: 16/9) {
  .app-shell {
    padding: 28px 30px 32px;
  }

  .app-frame {
    padding: 28px;
  }

  .dashboard {
    gap: 26px;
  }

  .panel {
    padding: 26px;
  }
}
