/* Planville Club Solar Challenge — Design aus Figma (Frame 960:209) */
:root {
  --hero-from: #204732;
  --hero-to: #202b1f;
  --band-dark: #203324;
  --vote-dark: #213123;
  --green: #3a9864;
  --green-icon: #399c61;
  --orange: #f69900;
  --gray-bg: #f8f8f8;
  --text-dark: #202b1f;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-900: #0f172a;
  --border: #cbd5e1;
  --red: #e90d0d;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Poppins', sans-serif;
  color: var(--text-dark);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

.container { max-width: 1285px; margin: 0 auto; }

/* ---------------------------------------------------------------- Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  border-radius: 26px;
  font-family: 'Poppins', sans-serif;
  font-weight: 500;
  font-size: 14px;
  line-height: 24px;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: transform .15s ease, opacity .15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-orange { background: var(--orange); color: #000; }
.btn-outline-white { background: transparent; color: #fff; border: 1px solid #fff; }
.btn-outline-black { background: transparent; color: #000; border: 1px solid #000; }
.btn[disabled] { opacity: .55; cursor: default; transform: none; }

/* ------------------------------------------------------- Deko-Viertelkreise */
.deco {
  position: absolute;
  width: 128px;
  height: 128px;
  pointer-events: none;
}
.deco::before, .deco::after { content: ""; position: absolute; left: 0; right: 0; }
.deco { background: var(--deco-a, #203b29); }
.deco::before { top: 0; bottom: 50%; background: var(--deco-b, #20422e); border-bottom-left-radius: 2000px; }
.deco::after  { top: 50%; bottom: 0; background: var(--deco-c, #122415); border-bottom-left-radius: 2000px; }
.deco.rot90  { transform: rotate(90deg); }
.deco.rot180 { transform: rotate(180deg); }

/* ------------------------------------------------------------------- Hero */
.hero-track { position: relative; }
.hero {
  position: relative;
  min-height: 488px;
  background: linear-gradient(180deg, var(--hero-from) 0%, var(--hero-to) 100%);
  overflow: hidden;
  display: flex;
  align-items: center;
}

/* Scrollytelling-Modus: wird per JS aktiviert, wenn WebGL verfuegbar ist */
.hero-track.scrolly { height: 280vh; }
.scrolly .hero {
  position: sticky;
  top: 0;
  height: 100vh;
  min-height: 0;
}
#hero3d {
  position: absolute;
  inset: 0;
  z-index: 1;
  cursor: grab;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
#hero3d.dragging { cursor: grabbing; }
#hero3d canvas { display: block; }
.scrolly .hero-inner {
  position: relative;
  z-index: 2;
  pointer-events: none;
  max-width: 640px;
}
.scrolly .hero-inner h1 { font-size: clamp(32px, 3.6vw, 52px); text-shadow: 0 2px 24px rgba(10, 20, 14, .45); }
.scrolly .hero-inner p { text-shadow: 0 1px 12px rgba(10, 20, 14, .5); }
.scrolly .hero-actions a { pointer-events: auto; }

/* 3D-Labels (Glassmorphism-Chips) */
#hero3d-labels {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  overflow: hidden;
}
.h3d-label {
  position: absolute;
  left: 0;
  top: 0;
  opacity: 0;
  transition: opacity .25s ease;
  will-change: transform;
  pointer-events: none;
}
.h3d-chip {
  display: inline-block;
  padding: 7px 12px;
  border-radius: 10px;
  background: rgba(18, 30, 22, .38);
  border: 1px solid rgba(255, 255, 255, .16);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .02em;
  white-space: nowrap;
  box-shadow: 0 4px 18px rgba(0, 0, 0, .25);
}
.h3d-benefit {
  display: none;
  margin-top: 3px;
  font-size: 11px;
  font-weight: 400;
  color: rgba(255, 255, 255, .82);
  white-space: nowrap;
}
.h3d-label.active .h3d-benefit { display: block; }
.h3d-label.active .h3d-chip { border-color: rgba(246, 153, 0, .55); }
.h3d-line {
  position: absolute;
  top: 50%;
  width: 26px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255,255,255,.55), rgba(255,255,255,.1));
}
.h3d-label.side-right .h3d-line { right: 100%; transform: scaleX(-1); }
.h3d-label.side-left .h3d-line { left: 100%; }

/* Interaktions-Hinweis */
.hero3d-hint {
  position: absolute;
  z-index: 3;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  padding: 8px 16px;
  border-radius: 22px;
  background: rgba(18, 30, 22, .38);
  border: 1px solid rgba(255, 255, 255, .14);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: rgba(255, 255, 255, .85);
  font-size: 12px;
  opacity: 0;
  transition: opacity .5s ease;
  pointer-events: none;
  white-space: nowrap;
}
.scrolly .hero3d-hint { opacity: 1; }
.scrolly .hero3d-hint.hidden { opacity: 0; }

@media (max-width: 720px) {
  .scrolly .hero-inner { align-self: flex-start; padding-top: 14vh; }
  .h3d-benefit { white-space: normal; max-width: 180px; }
}
.hero .deco { --deco-a: #203b29; --deco-b: #20422e; --deco-c: #122415; bottom: -46px; }
.hero .deco.d1 { left: 0; }
.hero .deco.d2 { left: 128px; }
.hero-inner {
  position: relative;
  z-index: 1;
  padding: 113px 64px 100px;
  max-width: 922px;
}
.hero h1 {
  font-weight: 700;
  font-size: clamp(36px, 5vw, 60px);
  line-height: 1.147;
  color: #fff;
  max-width: 858px;
}
.hero p {
  margin-top: 24px;
  font-size: 12px;
  color: #fff;
  max-width: 347px;
}
.hero-actions { margin-top: 24px; display: flex; gap: 13px; flex-wrap: wrap; }

/* ------------------------------------------------------------ Warum-Sektion */
.why {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding: 62px 72px;
}
.why-text { max-width: 737px; }
.why .eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  color: #676767;
  letter-spacing: .02em;
}
.why h2 {
  margin-top: 16px;
  font-weight: 600;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.16;
  color: var(--text-dark);
  max-width: 455px;
}
.why-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.why-card {
  background: var(--gray-bg);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  gap: 9px;
  align-items: flex-start;
}
.icon-circle {
  width: 25px;
  height: 25px;
  min-width: 25px;
  border-radius: 50%;
  background: var(--green-icon);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}
.icon-circle svg { width: 14px; height: 14px; }
.icon-circle.orange { background: var(--orange); }
.why-card h3 { font-size: 12px; font-weight: 400; color: #000; }
.why-card p { margin-top: 4px; font-size: 12px; color: #414141; }
.why-photo {
  width: 361px;
  min-width: 300px;
  height: 383px;
  border-radius: 24px;
  object-fit: cover;
  flex-shrink: 0;
}

/* ------------------------------------------------------------ Bewerben-Band */
.apply-band {
  position: relative;
  background: var(--band-dark);
  min-height: 249px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  padding: 26px 90px;
}
.apply-band .deco { --deco-a: #002913; --deco-b: #105a31; --deco-c: #13462a; }
.apply-band .deco.d1 { left: -85px; top: 0; }
.apply-band .deco.d2 { left: -85px; top: 128px; }
.apply-band .deco.d3 { right: 128px; top: -4px; }
.apply-band .deco.d4 { right: 0; top: 0; }
.apply-band .solar-band {
  /* Geometrie aus Figma: unrotierte Box -36..1316 x 23..344 bei 1285er Band, dann -3 Grad.
     object-fit: cover haelt die Kurvenform bei jeder Viewport-Breite (Anker: oben rechts). */
  position: absolute;
  left: -2.8%;
  top: 23px;
  width: 105.3%;
  height: calc(100% + 72px); /* 249er Band: 23px oben + 95px Ueberhang unten = 321px */
  max-width: none;
  transform: rotate(-3deg);
  pointer-events: none;
}
.apply-band h2 {
  position: relative;
  font-weight: 800;
  font-size: clamp(34px, 4.7vw, 60px);
  line-height: .9;
  text-transform: uppercase;
  color: #fff;
}
.apply-band p {
  position: relative;
  font-weight: 600;
  font-size: clamp(22px, 2.8vw, 36px);
  color: #fff;
}

/* ------------------------------------------------------------ Formular */
.form-section {
  display: flex;
  gap: 40px;
  justify-content: center;
  align-items: flex-start;
  padding: 75px 72px;
  flex-wrap: wrap;
}
.form-intro { max-width: 456px; }
.form-intro h2 { font-weight: 600; font-size: clamp(26px, 3vw, 36px); color: var(--text-dark); }
.form-intro-items { margin-top: 24px; display: flex; flex-direction: column; gap: 12px; max-width: 385px; }
.intro-item {
  background: var(--gray-bg);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 12px;
}
.club-form {
  background: var(--gray-bg);
  border-radius: 12px;
  padding: 24px;
  width: 595px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.form-row { display: flex; gap: 18px; }
.form-row > .field-group { flex: 1; min-width: 0; }
.field-group { display: flex; flex-direction: column; gap: 6px; }
.field-group label {
  font-weight: 500;
  font-size: 14px;
  line-height: 20px;
  color: var(--slate-900);
}
.field-group label .req { color: var(--red); font-family: 'Inter', sans-serif; font-weight: 500; }
.field-group input,
.field-group select,
.field-group textarea {
  width: 100%;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 12px;
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  line-height: 24px;
  color: var(--slate-900);
}
.field-group input::placeholder,
.field-group textarea::placeholder { color: var(--slate-400); }
.field-group select {
  appearance: none;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%230f172a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}
.field-group textarea { min-height: 136px; resize: vertical; }
.field-hint { font-size: 14px; line-height: 20px; color: var(--slate-500); }
.form-checkboxes { display: flex; flex-direction: column; gap: 8px; }
.checkbox-row { display: flex; gap: 8px; align-items: flex-start; font-size: 12px; line-height: 14px; color: var(--slate-500); }
.checkbox-row input { margin-top: 1px; width: 14px; height: 14px; min-width: 14px; accent-color: var(--green); }
.checkbox-row a { color: var(--green); }
.form-submit { display: flex; justify-content: flex-end; }
.form-feedback { font-size: 13px; display: none; }
.form-feedback.error { display: block; color: var(--red); }
.form-feedback.success { display: block; color: var(--green); font-weight: 500; }

/* ------------------------------------------------------------ Marquee */
.marquee {
  background: var(--green);
  height: 64px;
  overflow: hidden;
  display: flex;
  align-items: center;
}
.marquee-track {
  display: flex;
  align-items: center;
  gap: 40px;
  white-space: nowrap;
  animation: marquee 30s linear infinite;
  will-change: transform;
}
.marquee-item {
  display: flex;
  align-items: center;
  gap: 40px;
  font-weight: 500;
  font-size: 24px;
  color: #fff;
}
.marquee-item img { width: 28px; height: 28px; }
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
}

/* ------------------------------------------------------------ Vote-Band */
.vote-band {
  position: relative;
  background: var(--vote-dark);
  min-height: 235px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 26px 24px;
  text-align: center;
}
.vote-band .wave {
  position: absolute;
  left: -2.5%;
  top: -110px;
  width: 104%;
  height: 424px;
  pointer-events: none;
}
.vote-band h2 {
  position: relative;
  font-weight: 800;
  font-size: clamp(34px, 4.5vw, 57.6px);
  text-transform: uppercase;
  color: #fff;
}
.vote-band p {
  position: relative;
  font-weight: 600;
  font-size: clamp(20px, 2.8vw, 36px);
  color: #fff;
}

/* ------------------------------------------------------------ Vereins-Karten */
.clubs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px;
  padding: 68px 52px;
  max-width: 1225px;
  margin: 0 auto;
}
.club-card {
  background: var(--gray-bg);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.club-card-header {
  position: relative;
  background: var(--green);
  height: 208px;
  overflow: hidden;
}
.club-card-header .deco {
  --deco-a: #328b5a; --deco-b: #105a31; --deco-c: #277248;
  width: 112.64px; height: 112.64px;
}
.club-card-header .deco::before, .club-card-header .deco::after { border-bottom-left-radius: 1760px; }
.club-card-header .deco.d1 { left: -5px; top: -10px; }
.club-card-header .deco.d2 { left: -5px; top: 102px; }
.club-card-header .deco.d3 { left: 107px; top: 102px; }
.club-card-header .deco.d4 { right: -70px; top: -1px; }
.vote-badge {
  position: absolute;
  left: 23px;
  top: 20px;
  background: #fff;
  border-radius: 12px;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12px;
  color: #000;
}
.club-card-body {
  padding: 30px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex: 1;
}
.club-card-body h3 { font-weight: 500; font-size: 24px; color: #000; }
.club-card-body .club-story { margin-top: 12px; font-size: 16px; color: var(--slate-500); }
.club-card-actions {
  margin-top: auto;
  display: flex;
  gap: 9px;
  justify-content: flex-end;
  align-items: center;
}

/* ------------------------------------------------------------ Vereinsprofil */
.profile-hero {
  position: relative;
  background: linear-gradient(180deg, var(--hero-from) 0%, var(--hero-to) 100%);
  overflow: hidden;
  padding: 80px 64px 64px;
  color: #fff;
}
.profile-hero .deco { --deco-a: #203b29; --deco-b: #20422e; --deco-c: #122415; bottom: -46px; }
.profile-hero .deco.d1 { left: 0; }
.profile-hero .deco.d2 { left: 128px; }
.profile-hero .back-link {
  position: relative;
  font-size: 13px;
  color: #cfe4d7;
  text-decoration: none;
}
.profile-hero .back-link:hover { color: #fff; }
.profile-hero h1 { position: relative; margin-top: 16px; font-weight: 700; font-size: clamp(30px, 4vw, 48px); }
.profile-meta { position: relative; margin-top: 10px; display: flex; gap: 10px; flex-wrap: wrap; }
.profile-meta span {
  background: rgba(255, 255, 255, .12);
  border-radius: 26px;
  padding: 5px 14px;
  font-size: 13px;
}
.profile-content { max-width: 820px; margin: 0 auto; padding: 56px 24px 72px; }
.profile-content h2 { font-weight: 600; font-size: 24px; }
.profile-content .story {
  margin-top: 14px;
  font-size: 17px;
  line-height: 1.7;
  color: #414141;
  white-space: pre-line;
}
.profile-vote {
  margin-top: 36px;
  background: var(--gray-bg);
  border-radius: 12px;
  padding: 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.profile-vote .count { display: flex; align-items: center; gap: 10px; font-size: 15px; }

/* ------------------------------------------------------------ Rechtsseiten */
.legal-hero {
  background: linear-gradient(180deg, var(--hero-from) 0%, var(--hero-to) 100%);
  padding: 72px 24px;
  text-align: center;
  color: #fff;
}
.legal-hero h1 { font-weight: 700; font-size: clamp(28px, 4vw, 44px); }
.legal-content { max-width: 820px; margin: 0 auto; padding: 56px 24px 72px; }
.legal-content h2 { margin-top: 36px; font-weight: 600; font-size: 22px; color: var(--text-dark); }
.legal-content h3 { margin-top: 22px; font-weight: 600; font-size: 17px; }
.legal-content p, .legal-content li { margin-top: 12px; font-size: 15px; line-height: 1.7; color: #414141; }
.legal-content ul { padding-left: 22px; }
.legal-content .stand { font-size: 13px; color: var(--slate-500); }

/* ------------------------------------------------------------ Admin */
.admin-content { max-width: 1180px; margin: 0 auto; padding: 48px 24px; overflow-x: auto; }
.admin-content h1 { font-size: 28px; font-weight: 600; }
.admin-user { margin-top: 8px; color: var(--slate-500); font-size: 14px; }
.admin-hint { margin-top: 12px; font-size: 13px; color: var(--slate-500); }
.admin-hint-warn { color: #b45309; font-weight: 500; }
.admin-table { margin-top: 24px; border-collapse: collapse; width: 100%; font-size: 13px; }
.admin-table th, .admin-table td { border: 1px solid #e2e8f0; padding: 8px 10px; text-align: left; vertical-align: top; }
.admin-table th { background: var(--gray-bg); }
.admin-table .row-pending { background: #fffbeb; }
.cell-story { max-width: 280px; }
.cell-actions { white-space: nowrap; }
.cell-actions form { display: inline; }
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
}
.badge-ok { background: #dcfce7; color: #166534; }
.badge-pending { background: #fef3c7; color: #92400e; }
.badge-demo { background: #e2e8f0; color: #475569; }
.btn-admin {
  font-family: 'Poppins', sans-serif;
  font-size: 12px;
  font-weight: 500;
  padding: 5px 10px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  margin-right: 4px;
}
.btn-approve { background: var(--green); color: #fff; }
.btn-reject { background: #fee2e2; color: #991b1b; }
.btn-admin:hover { opacity: .85; }

/* ------------------------------------------------------------ Footer */
.site-footer { background: var(--hero-to); color: #cfe4d7; padding: 36px 24px; }
.footer-inner {
  max-width: 1141px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-brand { font-weight: 600; color: #fff; }
.footer-nav { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-nav a { font-size: 13px; color: #cfe4d7; text-decoration: none; }
.footer-nav a:hover { color: #fff; text-decoration: underline; }
.footer-copy { font-size: 12px; }

/* ------------------------------------------------------------ Responsive */
@media (max-width: 1100px) {
  .clubs-grid { grid-template-columns: repeat(2, 1fr); }
  .why { flex-direction: column; align-items: flex-start; }
  .why-photo { width: 100%; height: 320px; }
}
@media (max-width: 720px) {
  .hero-inner { padding: 80px 24px 90px; }
  .why { padding: 48px 24px; }
  .why-grid { grid-template-columns: 1fr; }
  .apply-band { padding: 26px 24px; }
  .form-section { padding: 56px 24px; }
  .form-row { flex-direction: column; gap: 18px; }
  .clubs-grid { grid-template-columns: 1fr; padding: 48px 24px; }
  .profile-hero { padding: 64px 24px 56px; }
}
