:root {
  --bg: radial-gradient(circle at 20% 20%, #e9f1ff, #eef0ff 35%, #f8f9fb 70%);
  --bg-panel: rgba(255, 255, 255, 0.85);
  --border: rgba(255, 255, 255, 0.45);
  --primary: #6c5efb;
  --primary-dark: #4d3edb;
  --text: #101524;
  --text-light: rgba(16, 21, 36, 0.65);
  --success: #22c55e;
  --danger: #ef4444;
  --shadow-soft: 0 30px 60px rgba(60, 74, 123, 0.18);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

.required-asterisk {
  display: inline;
  margin-left: 0.2rem;
  color: #dc2626;
  font-weight: 700;
  white-space: nowrap;
}

body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, sans-serif;
  background: var(--bg);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.6;
}
html[data-theme='light'],
body[data-theme='light'] {
  color-scheme: light;
}
html[data-theme='dark'],
body[data-theme='dark'] {
  color-scheme: dark;
}
html[data-theme='dark'],
html[data-theme='dark'] body,
body[data-theme='dark'] {
  --bg: radial-gradient(circle at 20% 20%, #111827, #0f172a 40%, #020617 90%);
  --bg-panel: rgba(15, 23, 42, 0.82);
  --border: rgba(148, 163, 184, 0.24);
  --text: #e5e7eb;
  --text-light: rgba(203, 213, 225, 0.8);
  --shadow-soft: 0 30px 60px rgba(2, 6, 23, 0.55);
}
html[data-theme='dark'] .top-nav,
html[data-theme='dark'] .lang-dropdown__toggle,
html[data-theme='dark'] .lang-dropdown__menu,
html[data-theme='dark'] .profile-dropdown__toggle,
html[data-theme='dark'] .profile-dropdown__menu,
html[data-theme='dark'] .panel,
html[data-theme='dark'] .card,
html[data-theme='dark'] .hero__card,
html[data-theme='dark'] .hero__summary-card,
html[data-theme='dark'] .hero__highlights article,
html[data-theme='dark'] .list .student-card,
html[data-theme='dark'] .stat-card,
html[data-theme='dark'] .timeline__item,
html[data-theme='dark'] .support-escalation,
html[data-theme='dark'] .filters fieldset,
html[data-theme='dark'] details,
html[data-theme='dark'] .cookie-banner,
html[data-theme='dark'] .cookie-banner__dialog,
html[data-theme='dark'] .password-modal__dialog,
html[data-theme='dark'] .assistant-panel,
html[data-theme='dark'] .assistant-chip,
html[data-theme='dark'] .assistant-launcher__bubble,
html[data-theme='dark'] .profile-dropdown__actions a,
html[data-theme='dark'] .profile-dropdown__roles a,
html[data-theme='dark'] .profile-action-group,
html[data-theme='dark'] .profile-action-link,
html[data-theme='dark'] .profile-action-module {
  background: rgba(15, 23, 42, 0.88);
  border-color: rgba(148, 163, 184, 0.24);
  color: var(--text);
}
html[data-theme='dark'] input,
html[data-theme='dark'] select,
html[data-theme='dark'] textarea {
  background: rgba(15, 23, 42, 0.78);
  border-color: rgba(148, 163, 184, 0.32);
  color: var(--text);
}
html[data-theme='dark'] input::placeholder,
html[data-theme='dark'] textarea::placeholder {
  color: rgba(203, 213, 225, 0.62);
}
html[data-theme='dark'] select option {
  background: #0f172a;
  color: #e5e7eb;
}
html[data-theme='dark'] .carousel__nav,
html[data-theme='dark'] .profile-action-group__title,
html[data-theme='dark'] .profile-action-link__meta,
html[data-theme='dark'] .profile-dropdown__section-title,
html[data-theme='dark'] .profile-dropdown__mail {
  color: rgba(203, 213, 225, 0.8);
}
html[data-theme='dark'] .profile-action-link.is-featured {
  color: #fff;
}
html[data-theme='dark'] .profile-action-link.is-featured .profile-action-link__meta {
  color: rgba(255, 255, 255, 0.85);
}
html[data-theme='dark'] .assistant-msg--assistant {
  background: rgba(99, 102, 241, 0.22);
  color: #e2e8f0;
}
html[data-theme='dark'] .assistant-panel__close,
html[data-theme='dark'] .lang-label,
html[data-theme='dark'] .nav-links a,
html[data-theme='dark'] .logo,
html[data-theme='dark'] .profile-label,
html[data-theme='dark'] .muted {
  color: var(--text-light);
}
html[data-theme='dark'] .footer-links a {
  color: #a5b4fc;
}
html[data-theme='dark'] .profile-chevron,
html[data-theme='dark'] .lang-chevron {
  border-color: rgba(226, 232, 240, 0.75);
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid rgba(108, 94, 251, 0.45);
  outline-offset: 2px;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.lang-dropdown__option:focus-visible {
  box-shadow: 0 0 0 3px rgba(108, 94, 251, 0.2);
  border-color: rgba(108, 94, 251, 0.25);
}

.top-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem clamp(1rem, 6vw, 5rem);
  background: rgba(255, 255, 255, 0.78);
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(12px);
  box-shadow: 0 12px 30px rgba(48, 57, 90, 0.08);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text);
}

.logo img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 50%;
  box-shadow: 0 6px 18px rgba(16, 21, 36, 0.18);
}

.logo span {
  font-size: 0.9rem;
  line-height: 1.2;
  max-width: 220px;
}

.nav-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.95rem;
}

.nav-links a {
  text-decoration: none;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  color: var(--text-light);
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-links a:hover {
  background: rgba(108, 94, 251, 0.12);
  color: var(--text);
}

.nav-links a.active {
  background: var(--primary);
  color: white;
  box-shadow: 0 10px 25px rgba(108, 94, 251, 0.35);
}

body[data-page='home'] .nav-links a[data-nav='home'],
body[data-page='private'] .nav-links a[data-nav='private'],
body[data-page='catalog'] .nav-links a[data-nav='catalog'],
body[data-page='resources'] .nav-links a[data-nav='resources'],
body[data-page='contact'] .nav-links a[data-nav='contact'],
body[data-page='agenda'] .nav-links a[data-nav='agenda'],
body[data-page='register'] .nav-links a[data-nav='register'] {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 10px 25px rgba(108, 94, 251, 0.35);
}

.lang-dropdown {
  position: relative;
}

.lang-dropdown__toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(16, 21, 36, 0.15);
  background: rgba(255, 255, 255, 0.8);
  padding: 0.35rem 0.9rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(16, 21, 36, 0.08);
  color: var(--text);
}

.lang-dropdown__menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.4rem);
  background: #fff;
  border-radius: 1rem;
  border: 1px solid rgba(16, 21, 36, 0.08);
  box-shadow: 0 20px 40px rgba(16, 21, 36, 0.15);
  padding: 0.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  z-index: 5;
}

.lang-dropdown.open .lang-dropdown__menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-dropdown__option {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  border: none;
  background: transparent;
  padding: 0.45rem 0.6rem;
  border-radius: 0.8rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  color: var(--text);
}

.lang-dropdown__option span {
  color: var(--text);
}

.lang-dropdown__option.active,
.lang-dropdown__option:hover {
  background: rgba(108, 94, 251, 0.12);
  color: var(--text);
}

.lang-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
}

.lang-chevron {
  width: 0.5rem;
  height: 0.5rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

body[data-page] .lang-chevron {
  border-color: rgba(16, 21, 36, 0.8);
}

.lang-flag {
  width: 22px;
  height: 14px;
  border-radius: 2px;
  border: 1px solid rgba(16, 21, 36, 0.15);
  display: inline-block;
  background-size: cover;
  background-position: center;
}

.lang-flag-es {
  background-image: linear-gradient(to bottom, #c60b1e 33%, #ffc400 33%, #ffc400 66%, #c60b1e 66%);
}

.lang-flag-ca {
  background-image: repeating-linear-gradient(
    to bottom,
    #f6d04d 0 18%,
    #d70c17 18% 36%
  );
}

.lang-flag-en {
  background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA2MCAzMCI+PHBhdGggZmlsbD0iIzAxMjE2OSIgZD0iTTAgMGg2MHYzMEgweiIvPjxwYXRoIHN0cm9rZT0iI2ZmZiIgc3Ryb2tlLXdpZHRoPSI2IiBkPSJNMCAwbDYwIDMwTTYwIDBMMCAzMCIvPjxwYXRoIHN0cm9rZT0iI0M4MTAyRSIgc3Ryb2tlLXdpZHRoPSI0IiBkPSJNMCAwbDYwIDMwTTYwIDBMMCAzMCIvPjxwYXRoIHN0cm9rZT0iI2ZmZiIgc3Ryb2tlLXdpZHRoPSIxMCIgZD0iTTMwIDB2MzBNMCAxNWg2MCIvPjxwYXRoIHN0cm9rZT0iI0M4MTAyRSIgc3Ryb2tlLXdpZHRoPSI2IiBkPSJNMzAgMHYzME0wIDE1aDYwIi8+PC9zdmc+");
  background-size: cover;
  background-position: center;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2.5rem;
  padding: 3.5rem clamp(1rem, 6vw, 6rem) 2.5rem;
}

.hero__content ul {
  padding-left: 1.2rem;
  color: var(--text-light);
}

.hero__highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.hero__highlights article {
  border: 1px solid rgba(16, 21, 36, 0.1);
  border-radius: 1rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.9);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.hero__summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.hero__summary-card {
  border-radius: 1.2rem;
  padding: 1.5rem;
  border: 1px solid rgba(16, 21, 36, 0.1);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.hero__card {
  background: var(--bg-panel);
  border-radius: 1.35rem;
  padding: 2.2rem;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
}

.hero__card--inline {
  max-width: 420px;
  margin: 0 auto 1.5rem;
}

label {
  font-weight: 600;
  font-size: 0.9rem;
}

input,
textarea,
select,
button {
  font: inherit;
}

input,
textarea,
select {
  padding: 0.8rem 0.95rem;
  border-radius: 0.8rem;
  border: 1px solid rgba(16, 21, 36, 0.08);
  background: rgba(255, 255, 255, 0.9);
}

textarea {
  resize: vertical;
}

button {
  border: none;
  border-radius: 0.9rem;
  background: linear-gradient(135deg, var(--primary), #8b78ff);
  color: white;
  font-weight: 600;
  padding: 0.95rem 1.4rem;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

button:hover {
  transform: translateY(-1px) scale(1.01);
  box-shadow: 0 18px 35px rgba(108, 94, 251, 0.38);
}

button.secondary {
  background: transparent;
  border: 1px solid rgba(16, 21, 36, 0.15);
  color: var(--text);
}

main {
  padding: 1rem clamp(1rem, 6vw, 6rem) 4rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

#dashboard {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.panel {
  background: var(--bg-panel);
  border-radius: 1.6rem;
  padding: 2.5rem;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.panel--light {
  background: rgba(236, 238, 255, 0.8);
  box-shadow: none;
}

.panel--carousel {
  background: transparent;
  border: none;
  box-shadow: none;
  padding-top: 0;
}

.panel__header {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.grid--two {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.card {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: 1.2rem;
  padding: 1.75rem;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(10px);
}

.card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  gap: 1rem;
}

.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  background: rgba(108, 94, 251, 0.15);
  color: var(--primary-dark);
  font-size: 0.75rem;
  letter-spacing: 0.04rem;
  font-weight: 600;
}

.badge--secondary {
  background: rgba(16, 21, 36, 0.08);
  color: var(--text);
}

.list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.list .student-card {
  border: 1px solid rgba(16, 21, 36, 0.08);
  border-radius: 1rem;
  padding: 0.95rem;
  background: rgba(255, 255, 255, 0.95);
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.inline-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
}

.stat-card {
  border: 1px solid rgba(16, 21, 36, 0.08);
  border-radius: 1rem;
  padding: 0.9rem;
  background: rgba(255, 255, 255, 0.95);
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.timeline__item {
  border-left: 4px solid var(--primary);
  padding-left: 1rem;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 0.9rem;
  box-shadow: 0 18px 32px rgba(30, 34, 62, 0.08);
}

.timeline__item h4 {
  margin-bottom: 0.4rem;
}

.timeline__item small {
  color: var(--text-light);
}

.timeline__item button {
  margin-top: 0.5rem;
  background: transparent;
  border: 1px solid rgba(16, 21, 36, 0.15);
  color: var(--text);
  padding: 0.45rem 0.8rem;
  font-size: 0.85rem;
}

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

.form-error {
  color: var(--danger);
  font-size: 0.9rem;
  min-height: 1.1rem;
}

.form-success {
  color: var(--success);
  font-size: 0.9rem;
  min-height: 1.1rem;
}

.filters {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.filters fieldset {
  border: 1px solid rgba(16, 21, 36, 0.12);
  border-radius: 0.9rem;
  padding: 0.75rem 1rem;
}

.filter-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  background: rgba(108, 94, 251, 0.18);
  color: var(--primary-dark);
  font-size: 0.85rem;
}

.chatbot-preview {
  border: 2px dashed rgba(16, 21, 36, 0.15);
  border-radius: 1rem;
  padding: 1.5rem;
  min-height: 320px;
  background: white;
}

.chatbot-preview iframe,
.chatbot-preview div {
  width: 100%;
  height: 100%;
}

.support-escalation {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid rgba(16, 21, 36, 0.12);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.92);
}

.link-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.kpi-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin-top: 0;
}

.link-card {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.1rem;
  border-radius: 0.9rem;
  background: linear-gradient(135deg, var(--primary), #8b78ff);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}

.button-link:hover {
  background: var(--primary-dark);
}

.button-link--ghost {
  background: transparent;
  color: var(--primary-dark);
  border: 1px solid rgba(108, 94, 251, 0.4);
  box-shadow: none;
}

.cta-links {
  margin-top: 1rem;
}

.carousel {
  position: relative;
  overflow: hidden;
  border-radius: 1.5rem;
  box-shadow: var(--shadow-soft);
}

.carousel__slides {
  display: flex;
  transition: transform 0.45s ease;
}

.carousel__slide {
  min-width: 100%;
  min-height: 320px;
  background-image: var(--bg);
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: center;
}

.carousel__slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(16, 21, 36, 0.75), rgba(16, 21, 36, 0.2));
}

.carousel__content {
  position: relative;
  color: #fff;
  padding: 2rem;
  max-width: 380px;
}

.carousel__content .button-link {
  background: rgba(255, 255, 255, 0.9);
  color: var(--primary-dark);
}

.carousel__nav {
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.9);
}

.carousel__nav button {
  background: transparent;
  border: 1px solid rgba(16, 21, 36, 0.15);
  color: var(--text);
}

.carousel__nav button.active {
  background: var(--primary);
  color: #fff;
  border-color: transparent;
}

.kpi-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin-top: 0;
}

details {
  border: 1px solid rgba(16, 21, 36, 0.12);
  border-radius: 0.9rem;
  padding: 0.75rem 1rem;
  background: rgba(250, 251, 255, 0.85);
}

details + details {
  margin-top: 0.75rem;
}

details summary {
  cursor: pointer;
  font-weight: 600;
}

footer {
  text-align: center;
  padding: 2rem 1rem 4rem;
  color: var(--text-light);
  font-size: 0.85rem;
}

.footer-links {
  margin-top: 0.6rem;
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  font-weight: 600;
  font-size: 0.8rem;
}

.footer-links a {
  color: var(--primary-dark);
  text-decoration: none;
}

.cookie-banner {
  position: fixed;
  inset: 0;
  background: rgba(16, 21, 36, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 30;
}

.cookie-banner__dialog {
  width: min(480px, 100%);
  background: rgba(255, 255, 255, 0.98);
  border-radius: 1.4rem;
  padding: 1.75rem;
  border: 1px solid rgba(16, 21, 36, 0.1);
  box-shadow: 0 30px 60px rgba(16, 21, 36, 0.2);
  text-align: left;
}

.cookie-banner__dialog p {
  margin: 0.75rem 0 0;
  font-size: 0.95rem;
  color: var(--text-light);
}

.cookie-banner__dialog a {
  color: var(--primary-dark);
  font-weight: 600;
}

.cookie-banner__actions {
  margin-top: 1.5rem;
  display: flex;
  justify-content: flex-end;
}

.password-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(16, 21, 36, 0.6);
  padding: 1rem;
  z-index: 40;
}

.password-modal__dialog {
  width: min(520px, 100%);
  background: #fff;
  border-radius: 1.5rem;
  padding: 2rem;
  box-shadow: 0 30px 60px rgba(16, 21, 36, 0.25);
  border: 1px solid rgba(16, 21, 36, 0.08);
}

.muted {
  color: var(--text-light);
  text-align: left;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}

@media (max-width: 720px) {
  .nav-links {
    justify-content: center;
  }

  .hero__card,
  .panel {
    padding: 1.75rem;
  }

  button {
    width: 100%;
  }

  .inline-group {
    width: 100%;
  }

  .cookie-banner {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Assistant widget */
.assistant-launcher {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #8b78ff);
  color: #fff;
  border: none;
  box-shadow: 0 20px 40px rgba(16, 21, 36, 0.25);
  cursor: pointer;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
}
.assistant-launcher__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.assistant-launcher__icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.assistant-launcher__bubble {
  position: absolute;
  right: calc(100% + 0.5rem);
  white-space: nowrap;
  background: #fff;
  color: var(--text);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  box-shadow: var(--shadow-soft);
  font-size: 0.8rem;
}
.assistant-panel {
  position: fixed;
  bottom: 5.5rem;
  right: 1.5rem;
  width: min(360px, 90vw);
  max-height: min(520px, 80vh);
  background: rgba(255, 255, 255, 0.98);
  border-radius: 1.4rem;
  padding: 1rem;
  border: 1px solid rgba(16, 21, 36, 0.08);
  box-shadow: 0 25px 60px rgba(16, 21, 36, 0.25);
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 40;
  display: flex;
  flex-direction: column;
}
.assistant-panel.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.assistant-panel__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}
.assistant-panel__close {
  border: none;
  background: transparent;
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
}
.assistant-chat {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  height: 100%;
}
.assistant-chat--full {
  min-height: 420px;
}
.assistant-chat--floating {
  height: 360px;
}
.assistant-chat__messages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding-right: 0.25rem;
}
.assistant-msg {
  max-width: 90%;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  box-shadow: 0 12px 32px rgba(16, 21, 36, 0.12);
  font-size: 0.92rem;
  line-height: 1.4;
}
.assistant-msg--assistant {
  align-self: flex-start;
  background: rgba(108, 94, 251, 0.1);
  color: var(--text);
}
.assistant-msg--user {
  align-self: flex-end;
  background: linear-gradient(135deg, var(--primary), #8b78ff);
  color: #fff;
}
.assistant-chat__composer {
  display: flex;
  gap: 0.5rem;
}
.assistant-chat__composer textarea {
  flex: 1;
  min-height: 48px;
  resize: none;
}
.assistant-chat__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.assistant-chat__chips-title {
  width: 100%;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-light);
}
.assistant-chip {
  border: 1px solid rgba(16, 21, 36, 0.12);
  border-radius: 999px;
  background: #fff;
  padding: 0.4rem 0.95rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--text);
  box-shadow: 0 5px 18px rgba(16, 21, 36, 0.08);
}
.assistant-chip:hover {
  border-color: rgba(108, 94, 251, 0.5);
  color: var(--primary-dark);
  box-shadow: 0 8px 24px rgba(108, 94, 251, 0.18);
}
.assistant-page-header {
  margin-bottom: 1rem;
}
@media (max-width: 720px) {
  .assistant-launcher {
    bottom: 1rem;
    right: 1rem;
  }
  .assistant-panel {
    right: 0.75rem;
    left: 0.75rem;
    width: auto;
  }
}
@media (max-width: 1080px) {
  .top-nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.6rem;
  }
  .nav-links {
    width: 100%;
    justify-content: center;
  }
  .hero,
  main {
    padding-left: clamp(0.75rem, 4vw, 4rem);
    padding-right: clamp(0.75rem, 4vw, 4rem);
  }
}
@media (max-width: 768px) {
  .top-nav {
    flex-direction: column;
    align-items: flex-start;
  }
  .nav-links {
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 0.4rem;
    gap: 0.5rem;
  }
  .nav-links a {
    flex: 0 0 auto;
  }
  .hero {
    grid-template-columns: 1fr;
  }
  .hero__summary {
    grid-template-columns: 1fr;
  }
  .panel,
  .hero__card {
    padding: 1.5rem;
  }
}
@media (max-width: 480px) {
  body {
    font-size: 15px;
  }
  .cta-row {
    flex-direction: column;
  }
  .lang-dropdown {
    align-self: stretch;
    width: 100%;
  }
  .assistant-launcher__bubble {
    display: none;
  }
}
@media (min-width: 1400px) {
  .hero,
  main {
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
  }
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.profile-dropdown {
  position: relative;
}

.profile-dropdown__toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(16, 21, 36, 0.12);
  background: rgba(255, 255, 255, 0.9);
  padding: 0.35rem 0.85rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(16, 21, 36, 0.08);
  color: var(--text);
}

.profile-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(108, 94, 251, 0.12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}

.profile-label {
  font-size: 0.85rem;
}

.profile-chevron {
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid rgba(16, 21, 36, 0.5);
  border-bottom: 2px solid rgba(16, 21, 36, 0.5);
  transform: rotate(45deg);
}

.profile-dropdown__menu {
  position: absolute;
  top: calc(100% + 0.4rem);
  right: 0;
  width: min(320px, 80vw);
  background: #fff;
  border-radius: 1.25rem;
  border: 1px solid rgba(16, 21, 36, 0.08);
  box-shadow: 0 25px 60px rgba(16, 21, 36, 0.2);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 15;
}

.profile-dropdown.open .profile-dropdown__menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.profile-dropdown__header {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.profile-dropdown__name {
  font-weight: 700;
  margin: 0;
}

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

.profile-dropdown__section {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.profile-dropdown__section-title {
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-light);
  margin: 0;
}

.profile-dropdown__actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.45rem;
  max-height: 19rem;
  overflow: auto;
  padding-right: 0.2rem;
}

.profile-dropdown__roles {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.profile-dropdown__actions a {
  border: 1px solid rgba(16, 21, 36, 0.12);
  border-radius: 0.9rem;
  padding: 0.55rem 0.7rem;
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.95);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.profile-dropdown__actions a:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(16, 21, 36, 0.12);
  border-color: rgba(79, 70, 229, 0.28);
}

.profile-dropdown__roles a {
  border: 1px solid rgba(16, 21, 36, 0.12);
  border-radius: 999px;
  padding: 0.3rem 0.85rem;
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.95);
}

.profile-action__label {
  line-height: 1.2;
}

.profile-action__tag {
  font-size: 0.64rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 999px;
  padding: 0.22rem 0.5rem;
  background: rgba(16, 21, 36, 0.08);
  color: var(--text-light);
  white-space: nowrap;
}

.profile-action--neutral {
  background: rgba(255, 255, 255, 0.96);
}

.profile-action--commerce {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.16), rgba(59, 130, 246, 0.06));
  border-color: rgba(79, 70, 229, 0.34);
}

.profile-action--commerce .profile-action__tag {
  background: rgba(79, 70, 229, 0.14);
  color: #4338ca;
}

.profile-action--primary {
  background: linear-gradient(135deg, #635bff, #4f46e5);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 12px 30px rgba(79, 70, 229, 0.32);
}

.profile-action--primary .profile-action__tag {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.profile-dropdown__actions {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  max-height: 22rem;
  overflow: auto;
  padding-right: 0.2rem;
}

.profile-action-group {
  display: grid;
  gap: 0.45rem;
  padding: 0.58rem;
  border: 1px solid rgba(16, 21, 36, 0.1);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.92);
}

.profile-action-group__title {
  margin: 0;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-light);
  font-weight: 700;
}

.profile-action-group__list {
  display: grid;
  gap: 0.4rem;
}

.profile-dropdown__actions a {
  border-radius: 0.78rem;
  padding: 0.52rem 0.66rem;
  font-weight: 600;
}

.profile-action__label {
  font-weight: 700;
  line-height: 1.2;
}

.profile-action__arrow {
  font-size: 0.95rem;
  color: var(--text-light);
  font-weight: 700;
  line-height: 1;
}

.profile-action__tag {
  display: none !important;
}

.profile-action--commerce {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(59, 130, 246, 0.04));
  border-color: rgba(79, 70, 229, 0.2);
}

.profile-action--primary {
  background: linear-gradient(135deg, #635bff, #4f46e5);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 10px 22px rgba(79, 70, 229, 0.26);
}

.profile-action--primary .profile-action__arrow {
  color: rgba(255, 255, 255, 0.92);
}

.profile-action-board {
  display: grid;
  gap: 0.7rem;
}

.profile-action-module {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid rgba(16, 21, 36, 0.1);
  background: linear-gradient(170deg, rgba(255, 255, 255, 0.98), rgba(246, 249, 255, 0.96));
  padding: 0.65rem;
  box-shadow: 0 12px 26px rgba(16, 21, 36, 0.08);
}

.profile-action-module::before {
  content: '';
  position: absolute;
  top: -1.6rem;
  right: -1.2rem;
  width: 5.2rem;
  height: 5.2rem;
  border-radius: 50%;
  background: radial-gradient(circle at center, rgba(99, 102, 241, 0.2), transparent 70%);
  pointer-events: none;
}

.profile-action-module--access::before {
  background: radial-gradient(circle at center, rgba(56, 189, 248, 0.2), transparent 70%);
}

.profile-action-module--catalog::before {
  background: radial-gradient(circle at center, rgba(99, 102, 241, 0.2), transparent 70%);
}

.profile-action-module--private::before {
  background: radial-gradient(circle at center, rgba(34, 197, 94, 0.18), transparent 70%);
}

.profile-action-module__title {
  margin: 0;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #2f3d63;
  font-weight: 800;
}

.profile-action-module__desc {
  margin: 0.15rem 0 0;
  font-size: 0.74rem;
  color: var(--text-light);
  line-height: 1.35;
}

.profile-action-module__grid {
  margin-top: 0.55rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
}

.profile-action-link {
  border: 1px solid rgba(16, 21, 36, 0.13);
  border-radius: 0.78rem;
  background: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  color: var(--text);
  padding: 0.46rem 0.58rem;
  display: grid;
  gap: 0.08rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.profile-action-link:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(16, 21, 36, 0.12);
  border-color: rgba(79, 70, 229, 0.35);
}

.profile-action-link.is-featured {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, #635bff, #4f46e5);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 14px 28px rgba(79, 70, 229, 0.28);
}

.profile-action-link__label {
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.2;
}

.profile-action-link__meta {
  font-size: 0.67rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #516082;
}

.profile-action-link.is-featured .profile-action-link__meta {
  color: rgba(255, 255, 255, 0.84);
}

.profile-dropdown__actions .profile-action-link {
  display: grid;
  align-items: stretch;
  justify-content: flex-start;
  gap: 0.08rem;
}

.profile-dropdown__actions .profile-action-link__label {
  white-space: normal;
  overflow-wrap: anywhere;
}

.profile-dropdown__actions .profile-action-link__meta {
  display: none !important;
}

@media (max-width: 560px) {
  .profile-action-module__grid {
    grid-template-columns: 1fr;
  }
}

.profile-dropdown__logout {
  border: none;
  border-radius: 0.9rem;
  background: rgba(239, 68, 68, 0.1);
  color: #b91c1c;
  font-weight: 600;
  padding: 0.6rem 1rem;
  cursor: pointer;
}

@media (max-width: 768px) {
  .nav-actions {
    width: 100%;
    justify-content: space-between;
  }
  .profile-dropdown__menu {
    right: -1rem;
  }
}

