/* page.css — AISUS.agency page-specific styles */

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  padding-top: var(--space-16);
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.35;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: 
    linear-gradient(180deg, 
      var(--color-bg) 0%, 
      oklch(from var(--color-bg) l c h / 0.5) 30%,
      oklch(from var(--color-bg) l c h / 0.3) 60%,
      var(--color-bg) 100%
    );
}

.hero__particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
}

.hero__badge {
  animation: fadeInDown 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hero__logo {
  animation: fadeInDown 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
  margin-bottom: var(--space-2);
}

.aisus-logo-hero {
  filter: drop-shadow(0 0 20px oklch(from var(--color-primary) l c h / 0.3));
}

.hero__title {
  font-size: var(--text-3xl);
  font-weight: 700;
  line-height: 1.05;
  animation: fadeInDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

@media (min-width: 768px) {
  .hero__title {
    font-size: var(--text-hero);
  }
}

.hero__subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 600px;
  animation: fadeInDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

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

.hero__stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-4);
  animation: fadeInDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.3s both;
  width: 100%;
  max-width: 700px;
}

.stat-card {
  background: oklch(from var(--color-surface) l c h / 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid oklch(from var(--color-text) l c h / 0.08);
  border-radius: var(--radius-xl);
  padding: var(--space-4) var(--space-6);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
  flex: 1;
  min-width: 140px;
}

.stat-card__value {
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1;
}

.stat-card__suffix {
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1;
  margin-left: -4px;
}

.stat-card__label {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.stat-card__icon {
  margin-bottom: var(--space-1);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  justify-content: center;
  animation: fadeInDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.4s both;
}

.btn--lg {
  padding: var(--space-4) var(--space-8);
}

.btn--sm {
  padding: var(--space-2) var(--space-4);
}

.hero__scroll-hint {
  position: absolute;
  bottom: var(--space-8);
  z-index: 2;
  opacity: 0.5;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

.scroll-dot {
  animation: scrollDot 2s infinite;
}

@keyframes scrollDot {
  0% { cy: 10; opacity: 1; }
  100% { cy: 22; opacity: 0; }
}

@keyframes fadeInDown {
  from { opacity: 0; }
  to { opacity: 1; }
}

.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.5); }
}

/* ===== SECTION HEADERS ===== */
.section-header {
  text-align: center;
  margin-bottom: clamp(var(--space-10), 5vw, var(--space-16));
}

.section-label {
  font-size: var(--text-xs);
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 500;
  display: block;
  margin-bottom: var(--space-2);
}

.section-title {
  font-size: var(--text-2xl);
  font-weight: 700;
  margin-bottom: var(--space-3);
}

.section-desc {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 540px;
  margin-inline: auto;
}

.section--alt {
  background: var(--color-surface);
}

/* ===== PHILOSOPHY ===== */
.philosophy-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

@media (min-width: 640px) {
  .philosophy-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .philosophy-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* 8-pillar layout: clean 2x4 → 4x2 grid */
@media (min-width: 640px) {
  .philosophy-grid--8 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .philosophy-grid--8 {
    grid-template-columns: repeat(4, 1fr);
  }
}

.philosophy-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.philosophy-card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
  background: oklch(from var(--color-primary) l c h / 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
}

.philosophy-card__title {
  font-size: var(--text-base);
  font-weight: 600;
}

.philosophy-card__text {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

/* ===== TOKEN ===== */
.token-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-10);
}

@media (min-width: 1024px) {
  .token-layout {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

.token-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.token-features li {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.token-stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-8);
}

.token-stat-card {
  background: var(--color-surface-offset);
  border: 1px solid oklch(from var(--color-text) l c h / 0.06);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.token-stat-card__label {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.token-stat-card__value {
  font-size: var(--text-lg);
  font-weight: 700;
}

.token-stat-card__suffix {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* Donut Chart */
.token-chart-wrapper {
  background: var(--color-surface-offset);
  border: 1px solid oklch(from var(--color-text) l c h / 0.06);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
}

.donut-chart {
  max-width: 240px;
  margin: 0 auto var(--space-6);
}

.donut-svg {
  width: 100%;
  transform: rotate(-90deg);
}

.donut-svg text {
  transform: rotate(90deg);
  transform-origin: 100px 100px;
}

.donut-legend {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.legend-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

/* ===== INFRASTRUCTURE ===== */
.infra-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 480px) {
  .infra-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .infra-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  .infra-grid--3col {
    grid-template-columns: repeat(3, 1fr);
  }
}

.infra-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-6) var(--space-4);
}

.infra-card__emoji {
  font-size: 2rem;
  margin-bottom: var(--space-1);
}

.infra-card__title {
  font-size: var(--text-sm);
  font-weight: 600;
}

.infra-card__text {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* ===== INFRA SUB-SECTIONS ===== */
.infra-sub {
  margin-top: var(--space-12);
}

.infra-sub:first-child {
  margin-top: var(--space-8);
}

.infra-sub__heading {
  font-size: var(--text-lg);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid oklch(from var(--color-text) l c h / 0.08);
}

.infra-sub__desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  max-width: 680px;
  line-height: 1.7;
  margin-bottom: var(--space-6);
}

/* ===== FLEET SHOWCASE (Campervans) ===== */
.fleet-showcase {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 640px) {
  .fleet-showcase {
    grid-template-columns: repeat(2, 1fr);
  }
}

.fleet-card {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  padding: var(--space-5);
  transition: border-color 180ms cubic-bezier(0.16, 1, 0.3, 1);
}

.fleet-card:hover {
  border-color: oklch(from var(--color-secondary) l c h / 0.3);
}

.fleet-card__badge {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  background: oklch(from var(--color-secondary) l c h / 0.12);
  color: var(--color-secondary);
  font-size: var(--text-xs);
  font-weight: 700;
}

.fleet-card__body {
  flex: 1;
  min-width: 0;
}

.fleet-card__name {
  font-size: var(--text-sm);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.fleet-card__spec {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-3);
}

.fleet-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.fleet-tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: oklch(from var(--color-primary) l c h / 0.1);
  color: var(--color-primary);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.fleet-features {
  margin-top: var(--space-6);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4) var(--space-6);
  padding: var(--space-5);
  background: oklch(from var(--color-surface) l c h / 0.5);
  border: 1px solid oklch(from var(--color-text) l c h / 0.06);
  border-radius: var(--radius-xl);
}

.fleet-feature {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* ===== CAMP GRID ===== */
.camp-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 480px) {
  .camp-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .camp-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.camp-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-5);
}

.camp-card__icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  background: oklch(from var(--color-primary) l c h / 0.08);
  margin-bottom: var(--space-1);
}

.camp-card__title {
  font-size: var(--text-sm);
  font-weight: 600;
}

.camp-card__text {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* ===== FARM LAYOUT ===== */
.farm-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

@media (min-width: 768px) {
  .farm-layout {
    grid-template-columns: 1fr 1fr;
  }
}

.farm-hero-card {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  border-left: 3px solid var(--color-primary);
}

.farm-hero-card__icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-xl);
  background: oklch(from var(--color-primary) l c h / 0.1);
}

.farm-hero-card__title {
  font-size: var(--text-lg);
  font-weight: 700;
}

.farm-hero-card__text {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

.farm-hero-card__stats {
  display: flex;
  gap: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid oklch(from var(--color-text) l c h / 0.08);
}

.farm-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.farm-stat__value {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-primary);
}

.farm-stat__label {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.farm-side {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.farm-card {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-4);
}

.farm-card__emoji {
  font-size: 1.5rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.farm-card__title {
  font-size: var(--text-sm);
  font-weight: 600;
  margin-bottom: 2px;
}

.farm-card__text {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* ===== LOCATION ===== */
.location-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-10);
}

@media (min-width: 768px) {
  .location-layout {
    grid-template-columns: 1fr 1fr;
    align-items: center;
  }
}

.location-requirements {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.location-requirements li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
}

.location-requirements li svg {
  flex-shrink: 0;
  margin-top: 2px;
}

.location-requirements li div {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.location-requirements li strong {
  font-size: var(--text-sm);
  font-weight: 600;
}

.location-requirements li span {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.map-container {
  position: relative;
  background: var(--color-surface-offset);
  border: 1px solid oklch(from var(--color-text) l c h / 0.06);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  overflow: hidden;
}

.iberian-map {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
}

.map-overlay {
  position: absolute;
  bottom: var(--space-4);
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
}

/* ===== JOIN ===== */
.join-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-10);
}

@media (min-width: 768px) {
  .join-layout {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

.category-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.category-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-lg);
  transition: background var(--transition-interactive);
}

.category-item:hover {
  background: var(--color-surface);
}

.category-item--highlight {
  background: oklch(from var(--color-secondary) l c h / 0.08);
  border: 1px solid oklch(from var(--color-secondary) l c h / 0.15);
}

.category-item--highlight:hover {
  background: oklch(from var(--color-secondary) l c h / 0.12);
}

.category-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  line-height: 1;
}

.category-item div {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.category-item strong {
  font-size: var(--text-sm);
  font-weight: 600;
}

.category-item span {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.form-group {
  margin-bottom: var(--space-4);
}

/* ===== ROADMAP / TIMELINE ===== */
.timeline {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
  padding-left: var(--space-8);
}

.timeline__line {
  position: absolute;
  left: var(--space-3);
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--color-primary), var(--color-secondary), var(--color-border));
}

.timeline__item {
  position: relative;
  margin-bottom: var(--space-6);
}

.timeline__marker {
  position: absolute;
  left: calc(var(--space-3) * -1 - var(--space-8) + 6px);
  top: var(--space-4);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--color-surface-dynamic);
  border: 2px solid var(--color-border);
  z-index: 1;
}

.timeline__marker--active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  box-shadow: 0 0 12px oklch(from var(--color-primary) l c h / 0.4);
}

.timeline__content {
  padding: var(--space-4) var(--space-5);
}

/* ===== FOOTER ===== */
.footer {
  border-top: 1px solid var(--color-divider);
  padding-block: var(--space-12);
  background: var(--color-bg);
}

.footer__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  margin-bottom: var(--space-8);
}

@media (min-width: 768px) {
  .footer__inner {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer__link {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color var(--transition-interactive);
}

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

.footer__status {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-2);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  padding-top: var(--space-6);
  border-top: 1px solid var(--color-divider);
}

/* ===== THEME TOGGLE ===== */
.theme-toggle {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  transition: color var(--transition-interactive),
              background var(--transition-interactive);
}

.theme-toggle:hover {
  color: var(--color-text);
  background: var(--color-surface);
}

/* ===== RESPONSIVE REFINEMENTS ===== */
@media (max-width: 479px) {
  .hero__stats {
    flex-direction: column;
    align-items: stretch;
  }
  
  .stat-card {
    min-width: unset;
  }
  
  .hero__actions {
    flex-direction: column;
    width: 100%;
    padding-inline: var(--space-4);
  }
  
  .hero__actions .btn {
    width: 100%;
  }
  
  .token-stats-row {
    grid-template-columns: 1fr;
  }
  
  .map-overlay {
    position: static;
    transform: none;
    text-align: center;
    margin-top: var(--space-4);
    white-space: normal;
  }

  .timeline {
    padding-left: var(--space-6);
  }
  
  .timeline__marker {
    left: calc(var(--space-3) * -1 - var(--space-6) + 6px);
  }
}

/* Particle styles */
.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 50%;
  opacity: 0;
  animation: float linear infinite;
}

@keyframes float {
  0% {
    opacity: 0;
    transform: translateY(0) scale(0);
  }
  10% {
    opacity: 0.6;
    transform: scale(1);
  }
  90% {
    opacity: 0.2;
  }
  100% {
    opacity: 0;
    transform: translateY(-100vh) scale(0.5);
  }
}

/* ===== ZERO TOLERANCE SECTION ===== */
.zt-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
}

@media (min-width: 768px) {
  .zt-layout {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

.zt-main-card {
  padding: var(--space-8);
  border-left: 3px solid var(--color-secondary);
}

.zt-icon-wrapper {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-xl);
  background: oklch(from var(--color-secondary) l c h / 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
}

.zt-agreement {
  background: oklch(from var(--color-secondary) l c h / 0.06);
  border: 1px solid oklch(from var(--color-secondary) l c h / 0.15);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.zt-details {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 480px) and (max-width: 767px) {
  .zt-details {
    grid-template-columns: repeat(2, 1fr);
  }
}

.zt-detail-card {
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.zt-detail-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: oklch(from var(--color-primary) l c h / 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-1);
}

/* ===== GOVERNANCE & LEGAL ===== */
.formula-box {
  background: var(--color-surface-offset);
  border: 1px solid oklch(from var(--color-primary) l c h / 0.2);
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  font-family: 'Space Grotesk', monospace;
  font-size: var(--text-sm);
  color: var(--color-primary);
  text-align: center;
  overflow-x: auto;
}

.formula-box code {
  white-space: nowrap;
}

/* Participation Levels */
.level-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
}

@media (min-width: 480px) {
  .level-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.level-item {
  background: var(--color-surface-offset);
  border: 1px solid oklch(from var(--color-text) l c h / 0.06);
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.level-badge {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.level-badge--guest { color: var(--color-text-muted); }
.level-badge--member { color: var(--color-primary); }
.level-badge--citizen { color: var(--color-secondary); }
.level-badge--founder { color: #00cc88; }

.level-tokens {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  font-weight: 600;
}

.level-desc {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

/* Legal Structure Diagram */
.legal-diagram {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.legal-node {
  background: var(--color-surface-offset);
  border: 1px solid oklch(from var(--color-text) l c h / 0.1);
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-5);
  text-align: center;
  width: 100%;
  max-width: 280px;
}

.legal-node--top {
  border-color: var(--color-primary);
  background: oklch(from var(--color-primary) l c h / 0.06);
}

.legal-node--bottom {
  border-color: var(--color-secondary);
  background: oklch(from var(--color-secondary) l c h / 0.06);
}

.legal-node__label {
  display: block;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}

.legal-node__sub {
  display: block;
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.legal-arrow {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  padding: var(--space-1) 0;
  text-align: center;
}

/* ===== VOTING SECTION ===== */
.voting-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  position: relative;
}

@media (min-width: 640px) {
  .voting-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .voting-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.voting-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--space-5);
  transition: border-color var(--transition-interactive),
              box-shadow var(--transition-interactive),
              transform var(--transition-interactive);
}

.voting-card:hover {
  transform: translateY(-2px);
  border-color: oklch(from var(--color-primary) l c h / 0.4);
  box-shadow: 0 8px 32px oklch(from var(--color-primary) l c h / 0.12);
}

.voting-card__image {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-1);
  opacity: 0.88;
  transition: opacity var(--transition-interactive), transform 0.4s ease;
}
.voting-card:hover .voting-card__image {
  opacity: 1;
  transform: scale(1.02);
}
.voting-card__image-wrap {
  overflow: hidden;
  border-radius: var(--radius-md);
  margin: calc(-1 * var(--space-5)) calc(-1 * var(--space-5)) 0;
  width: calc(100% + 2 * var(--space-5));
}
.voting-card__runway-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 2px 10px;
  border-radius: var(--radius-sm);
  background: oklch(from var(--color-primary) l c h / 0.15);
  color: var(--color-primary);
  font-size: var(--text-xs);
  font-weight: 600;
  font-family: var(--font-display);
}
.voting-card__price-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
}

.voting-card__header {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.voting-card__flag {
  font-size: 1.25rem;
  line-height: 1;
}

.voting-card__country {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.voting-card__name {
  font-size: var(--text-base);
  font-weight: 600;
  line-height: 1.3;
}

.voting-card__price {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-primary);
}

.voting-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.voting-card__stat {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.voting-card__stat svg {
  flex-shrink: 0;
  color: var(--color-text-faint);
}

.voting-card__features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  flex-grow: 1;
}

.voting-card__features li {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.5;
  padding-left: var(--space-4);
  position: relative;
}

.voting-card__features li::before {
  content: '\2022';
  position: absolute;
  left: var(--space-1);
  color: var(--color-primary);
}

.voting-card__actions {
  margin-top: auto;
  padding-top: var(--space-3);
  border-top: 1px solid oklch(from var(--color-text) l c h / 0.06);
}

.vote-btn {
  width: 100%;
  position: relative;
}

.vote-btn.voted {
  background: var(--color-success);
  pointer-events: none;
}

.vote-btn.voted:hover {
  background: var(--color-success);
  box-shadow: none;
  transform: none;
}

.vote-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: oklch(from var(--color-text-inverse) l c h / 0.2);
  border-radius: var(--radius-full);
  min-width: 24px;
  height: 20px;
  font-size: 11px;
  font-weight: 700;
  padding: 0 var(--space-1);
  margin-left: var(--space-1);
}

/* Source links on voting cards */
.voting-card__source {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  margin-top: var(--space-2);
}

.voting-card__source a {
  color: var(--color-text-faint);
  text-decoration: none;
  transition: color var(--transition-interactive);
  font-size: 11px;
}

.voting-card__source a:hover {
  color: var(--color-primary);
  text-decoration: underline;
}

.voting-card__source svg {
  flex-shrink: 0;
  color: var(--color-text-faint);
  opacity: 0.5;
}

.voting-card__source-sep {
  color: var(--color-text-faint);
  opacity: 0.3;
  font-size: 10px;
}

/* Status badge for sold items */
.voting-card__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: oklch(from var(--color-warning) l c h / 0.15);
  color: var(--color-warning);
  margin-left: var(--space-2);
}

/* Registration Gate */
.registration-gate {
  display: none;
}

.registration-gate.is-active {
  display: block;
  margin-bottom: var(--space-8);
}

.registration-gate__overlay {
  display: flex;
  justify-content: center;
}

.registration-gate__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: var(--space-10) var(--space-8);
  max-width: 480px;
  width: 100%;
}

.voting-grid.is-locked {
  position: relative;
  pointer-events: none;
  user-select: none;
}

.voting-grid.is-locked::after {
  content: '';
  position: absolute;
  inset: 0;
  background: oklch(from var(--color-bg) l c h / 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border-radius: var(--radius-xl);
  z-index: 2;
}

/* ===== VISA SECTION ===== */
.visa-globe {
  font-size: 1.2em;
}

.visa-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  margin-bottom: var(--space-10);
}

@media (min-width: 768px) {
  .visa-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

.visa-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-6) var(--space-5);
  position: relative;
  overflow: hidden;
}

.visa-card__flag {
  font-size: 2.5rem;
  line-height: 1;
}

.visa-card__title {
  font-size: var(--text-xl);
  font-weight: 700;
}

.visa-card__type {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
}

.visa-card__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}

.visa-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: var(--space-3);
  background: oklch(from var(--color-text) l c h / 0.03);
  border-radius: var(--radius-lg);
}

.visa-stat--highlight {
  background: oklch(from var(--color-secondary) l c h / 0.1);
  border: 1px solid oklch(from var(--color-secondary) l c h / 0.2);
}

.visa-stat__label {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  font-weight: 500;
}

.visa-stat__value {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}

.visa-card__extras {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.visa-extra {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.visa-extra svg {
  flex-shrink: 0;
}

.visa-card__ease {
  margin-top: auto;
  padding-top: var(--space-3);
  border-top: 1px solid oklch(from var(--color-text) l c h / 0.06);
}

.visa-stars {
  font-size: var(--text-lg);
  color: var(--color-secondary);
  letter-spacing: 2px;
}

.visa-card--portugal {
  border-color: oklch(from var(--color-secondary) l c h / 0.25);
}

.visa-card--portugal:hover {
  border-color: oklch(from var(--color-secondary) l c h / 0.5);
  box-shadow: 0 0 32px oklch(from var(--color-secondary) l c h / 0.12);
}

.visa-card__highlight-badge {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  font-size: 11px;
  font-weight: 700;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  background: oklch(from var(--color-secondary) l c h / 0.15);
  color: var(--color-secondary);
  letter-spacing: 0.02em;
}

/* Visa Comparison Table */
.visa-table-wrapper {
  overflow-x: auto;
  margin-bottom: var(--space-8);
  -webkit-overflow-scrolling: touch;
}

.visa-table {
  width: 100%;
  min-width: 500px;
  border-collapse: collapse;
  font-size: var(--text-sm);
}

.visa-table th,
.visa-table td {
  padding: var(--space-3) var(--space-4);
  text-align: left;
  border-bottom: 1px solid oklch(from var(--color-text) l c h / 0.06);
}

.visa-table th {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  background: var(--color-surface);
  position: sticky;
  top: 0;
}

.visa-table td:first-child {
  font-weight: 500;
  color: var(--color-text-muted);
  font-size: var(--text-xs);
}

.visa-table__highlight-row {
  background: oklch(from var(--color-secondary) l c h / 0.05);
}

.visa-table__best {
  color: var(--color-secondary);
  font-weight: 700;
}

/* Visa Highlight Box */
.visa-highlight {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-6);
  background: oklch(from var(--color-secondary) l c h / 0.06);
  border: 1px solid oklch(from var(--color-secondary) l c h / 0.15);
  border-left: 3px solid var(--color-secondary);
  border-radius: var(--radius-xl);
}

.visa-highlight__icon {
  flex-shrink: 0;
  margin-top: 2px;
}

.visa-highlight p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

@media (max-width: 479px) {
  .visa-card__stats {
    grid-template-columns: 1fr;
  }
  
  .visa-highlight {
    flex-direction: column;
    gap: var(--space-2);
    padding: var(--space-4);
  }
}

/* ===== LANGUAGE SWITCHER ===== */
.lang-switcher {
  display: none;
  align-items: center;
  gap: 2px;
  padding: 2px;
  border-radius: var(--radius-full);
  background: oklch(from var(--color-text) l c h / 0.05);
}

@media (min-width: 768px) {
  .lang-switcher {
    display: flex;
  }
}

.lang-btn {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 4px 8px;
  border-radius: var(--radius-full);
  color: var(--color-text-faint);
  transition: color var(--transition-interactive),
              background var(--transition-interactive);
  line-height: 1;
}

.lang-btn:hover {
  color: var(--color-text-muted);
}

.lang-btn--active {
  color: var(--color-primary);
  background: oklch(from var(--color-primary) l c h / 0.12);
}

.mobile-lang-switcher {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: 1px solid oklch(from var(--color-text) l c h / 0.1);
}

.mobile-lang-switcher .lang-btn {
  font-size: var(--text-sm);
  padding: var(--space-2) var(--space-3);
}

/* Mobile adjustments for voting */
@media (max-width: 479px) {
  .voting-card {
    padding: var(--space-4);
  }
  
  .voting-card__meta {
    flex-direction: column;
    gap: var(--space-2);
  }
  
  .registration-gate__content {
    padding: var(--space-6) var(--space-4);
  }
}

/* ===== MODAL OVERLAY ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: oklch(0 0 0 / 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: var(--space-8) var(--space-4);
  overflow-y: auto;
  animation: modalFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-container {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  width: 100%;
  max-width: 640px;
  position: relative;
  animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-container--lg {
  max-width: 720px;
}

.modal-container--sm {
  max-width: 440px;
}

@keyframes modalSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.modal-close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  transition: color var(--transition-interactive), background var(--transition-interactive);
  z-index: 1;
}

.modal-close:hover {
  color: var(--color-text);
  background: oklch(from var(--color-text) l c h / 0.1);
}

.modal-header {
  text-align: center;
  margin-bottom: var(--space-6);
}

.modal-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-xl);
  background: oklch(from var(--color-primary) l c h / 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-3);
}

.modal-title {
  font-size: var(--text-xl);
  font-weight: 700;
}

.modal-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}

.modal-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: var(--space-8) 0;
}

/* Application form grid */
.app-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 480px) {
  .app-form-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Skills checkboxes */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-2);
}

@media (min-width: 480px) {
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.skill-check {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  cursor: pointer;
  font-size: var(--text-xs);
  transition: border-color var(--transition-interactive), background var(--transition-interactive);
}

.skill-check:hover {
  border-color: var(--color-primary);
  background: oklch(from var(--color-primary) l c h / 0.05);
}

.skill-check input:checked + span {
  color: var(--color-primary);
  font-weight: 600;
}

.skill-check input {
  accent-color: var(--color-primary);
  width: 14px;
  height: 14px;
}

/* Agreement checkboxes */
.agreement-check {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  cursor: pointer;
  line-height: 1.5;
}

.agreement-check input {
  accent-color: var(--color-primary);
  width: 16px;
  height: 16px;
  margin-top: 2px;
  flex-shrink: 0;
}

/* Form error */
.form-error {
  background: oklch(from var(--color-error) l c h / 0.1);
  border: 1px solid oklch(from var(--color-error) l c h / 0.3);
  color: var(--color-error);
  font-size: var(--text-xs);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  margin-top: var(--space-3);
}

/* Nav auth button */
.nav-auth-btn {
  font-size: var(--text-xs) !important;
  padding: var(--space-2) var(--space-3) !important;
}

.nav-user-info {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.nav-user-name {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Voting auth gate */
.voting-auth-gate {
  margin-bottom: var(--space-8);
}

.voting-auth-gate__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: var(--space-10) var(--space-8);
  max-width: 560px;
  margin: 0 auto;
}

@media (max-width: 479px) {
  .modal-container {
    padding: var(--space-5);
  }
  .skills-grid {
    grid-template-columns: 1fr 1fr;
  }
}
