/* ==========================================================================
   RentnerAiming – styles.css (mobile-first)
   ========================================================================== */

:root {
  --bg-0: #0a0a0a;
  --bg-1: #140a22;
  --panel: rgba(0, 0, 0, 0.50);
  --panel-2: rgba(0, 0, 0, 0.80);

  --purple: #6a1b9a;
  --purple-2: #9c27b0;
  --blue: #3b82f6;

  --text: #ffffff;
  --muted: #b0b0b0;

  --radius: 12px;
  --radius-lg: 15px;

  --shadow: 0 10px 40px rgba(0, 0, 0, 0.55);
  --border: 1px solid rgba(106, 27, 154, 0.30);

  --container: 1200px;
  --pad: 1.75rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html:focus-within {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background: linear-gradient(135deg, var(--bg-0) 0%, var(--bg-1) 100%);
  color: var(--text);
  min-height: 100vh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid rgba(59, 130, 246, 0.85);
  outline-offset: 3px;
  border-radius: 10px;
}

/* ==========================================================================
   Layout
   ========================================================================== */

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--pad);
}

.content {
  padding: 2rem 0 3rem;
}

@media (min-width: 768px) {
  :root { --pad: 3.5rem; }
  .content { padding: 3rem 0; }
}

/* ==========================================================================
   Header / Nav
   ========================================================================== */

.site-header {
  background: var(--panel-2);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 2px solid rgba(74, 20, 140, 0.95);
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.brand__logo {
  width: 32px;
  height: 32px;
}

.brand__text {
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--purple) 0%, #1e3a8a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 20px rgba(106, 27, 154, 0.5);
}

.nav-menu {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  padding: 0;
  margin: 0;
  align-items: center;
}

.nav-link {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font: inherit;
  padding: 0.4rem 0.2rem;
  min-height: 44px; /* touch target */
}

.nav-link:hover {
  color: var(--purple-2);
}

.mobile-menu-btn {
  display: none;
  border: 1px solid rgba(106, 27, 154, 0.35);
  background: rgba(0, 0, 0, 0.35);
  color: var(--text);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0.55rem 0.8rem;
  border-radius: 10px;
  min-height: 44px;
}

@media (max-width: 768px) {
  .brand__text { font-size: 1.4rem; }
  .brand__logo { width: 26px; height: 26px; }

  .mobile-menu-btn { display: inline-flex; align-items: center; justify-content: center; }

  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.95);
    flex-direction: column;
    gap: 0;
    padding: 0.75rem 0;
    border-top: 2px solid rgba(74, 20, 140, 0.95);
  }

  .nav-menu.active { display: flex; }

  .nav-menu li {
    padding: 0.25rem 1rem;
    border-bottom: 1px solid rgba(106, 27, 154, 0.2);
  }

  .nav-menu li:last-child { border-bottom: none; }

  .nav-link {
    width: 100%;
    text-align: left;
    padding: 0.8rem 0.6rem;
  }
}

/* ==========================================================================
   Pages / Animations
   ========================================================================== */

.page { display: none; }
.page.active { display: block; animation: fadeIn 0.45s ease both; }

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

@media (prefers-reduced-motion: reduce) {
  html:focus-within { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  text-align: center;
  padding: 2.5rem 1rem;
  background-image: url("../img/Homepage/Banner.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: rgba(0, 0, 0, 0.75);
  background-blend-mode: multiply;
  border-radius: var(--radius-lg);
  margin-bottom: 2rem;
  border: var(--border);
  box-shadow: var(--shadow);
}

@media (min-width: 768px) {
  .hero { padding: 4rem 1rem; margin-bottom: 3rem; }
}

.hero h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(2rem, 4vw, 3rem);
  background: linear-gradient(135deg, var(--purple-2) 0%, var(--blue) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p {
  margin: 0;
  font-size: 1.1rem;
  color: var(--muted);
}

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
  background: var(--panel);
  backdrop-filter: blur(10px);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  border: var(--border);
  box-shadow: var(--shadow);
}

@media (min-width: 768px) {
  .card { padding: 2rem; margin-bottom: 2rem; }
}

.card h2 {
  color: var(--purple-2);
  margin: 0 0 1rem;
}

.card p {
  margin: 0.75rem 0 0;
  line-height: 1.65;
  color: #e7e7e7;
}

.card p:first-of-type { margin-top: 0; }

.muted-note {
  margin-top: 0.75rem;
  color: var(--muted);
  font-style: italic;
}

.muted-footnote {
  margin-top: 0.75rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-style: italic;
}

.t-center { text-align: center; }

/* ==========================================================================
   Values list
   ========================================================================== */

.values-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.85rem;
}

.values-list li { line-height: 1.55; }

/* ==========================================================================
   Events
   ========================================================================== */

.event-list {
  display: grid;
  gap: 1.25rem;
}

.event-item {
  background: rgba(106, 27, 154, 0.10);
  padding: 1.25rem;
  border-radius: 10px;
  border-left: 4px solid var(--purple);
}

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

@media (max-width: 768px) {
  .event-header { flex-direction: column; align-items: flex-start; gap: 0.4rem; }
}

.event-title { font-size: 1.2rem; color: var(--text); font-weight: 700; }
.event-date { color: var(--purple-2); font-weight: 700; }
.event-capacity { color: var(--blue); margin-top: 0.5rem; font-size: 0.95rem; }

/* ==========================================================================
   Rules list
   ========================================================================== */

.rules-list {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: rule-counter;
}

.rules-list li {
  counter-increment: rule-counter;
  margin: 0 0 1.1rem;
  padding-left: 2rem;
  position: relative;
  line-height: 1.6;
}

.rules-list li::before {
  content: counter(rule-counter);
  position: absolute;
  left: 0;
  top: 0.05rem;
  background: linear-gradient(135deg, var(--purple) 0%, #1e3a8a 100%);
  color: var(--text);
  width: 26px;
  height: 26px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
}

/* ==========================================================================
   Tables
   ========================================================================== */

.rank-table {
  overflow-x: auto;
  margin-top: 1.5rem;
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(0, 0, 0, 0.30);
  border-radius: 10px;
  overflow: hidden;
}

th {
  background: linear-gradient(135deg, var(--purple) 0%, #1e3a8a 100%);
  color: var(--text);
  padding: 1rem;
  text-align: left;
  font-weight: 700;
  border-right: 1px solid rgba(106, 27, 154, 0.40);
}

th:last-child { border-right: none; }

td {
  padding: 0.8rem 1rem;
  border-bottom: 1px solid rgba(106, 27, 154, 0.20);
  border-right: 1px solid rgba(106, 27, 154, 0.20);
}

td:last-child { border-right: none; }

tr:hover { background: rgba(106, 27, 154, 0.10); }

.checkmark { color: #4CAF50; font-size: 1.1rem; text-align: center; }
.cross { color: #f44336; font-size: 1.1rem; text-align: center; }

.permission-table { margin-top: 2rem; }

.section-subtitle {
  color: var(--purple-2);
  margin: 2rem 0 1rem;
  font-size: 1.2rem;
}

.permission-table th {
  background: linear-gradient(135deg, #1e3a8a 0%, var(--purple) 100%);
}

@media (max-width: 768px) {
  table { min-width: 800px; }
  th, td { font-size: 0.85rem; padding: 0.6rem 0.55rem; }
  .rank-table { margin-left: -1.5rem; margin-right: -1.5rem; }
}

/* ==========================================================================
   Join / Recruitment block (NEU)
   ========================================================================== */

.join-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  align-items: center;
}

.join-media {
  margin: 0;
}

.join-media img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(106, 27, 154, 0.25);
  background: rgba(0, 0, 0, 0.25);
}

.join-bullets {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  gap: 0.55rem;
}

.join-bullets li {
  line-height: 1.55;
  color: #e7e7e7;
}

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

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

/* ==========================================================================
   Discord section
   ========================================================================== */

.discord-grid {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 2rem;
  align-items: center;
}

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

.discord-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.65rem 0.95rem;
  border-radius: 12px;
  color: #f3f4ff;
  text-decoration: none;
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.25);
  min-height: 44px;
}

.discord-link:hover {
  background: rgba(59, 130, 246, 0.18);
  border-color: rgba(59, 130, 246, 0.35);
}

.discord-link__icon { display: inline-flex; width: 20px; height: 20px; }

.discord-qr {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.discord-qr img {
  width: min(240px, 100%);
  border-radius: 12px;
  background: #fff;
  padding: 0.5rem;
}

@media (max-width: 768px) {
  .discord-grid { grid-template-columns: 1fr; }
  .discord-qr { justify-content: flex-start; margin-top: 1rem; }
}

/* ==========================================================================
   Legal
   ========================================================================== */

.legal-section { margin-bottom: 2rem; }

.legal-contact a {
  color: var(--purple-2);
  text-decoration: none;
}

.legal-contact a:hover { text-decoration: underline; }

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  text-align: center;
  padding: 2rem 0;
  color: #8a8a8a;
  border-top: 1px solid rgba(106, 27, 154, 0.2);
  margin-top: 2rem;
}

/* ==========================================================================
   Dojo tax section
   ========================================================================== */

.dojo-inline-block {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  margin: 1.25rem 0;
}

.dojo-inline-block.dojo-img-left  { flex-direction: row; }
.dojo-inline-block.dojo-text-left { flex-direction: row; }

.dojo-inline-text {
  flex: 1;
}

.dojo-inline-text p { margin: 0 0 0.75rem; line-height: 1.65; color: #e7e7e7; }
.dojo-inline-text p:last-child { margin-bottom: 0; }

.dojo-inline-imgs {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.dojo-inline-imgs img {
  width: 200px;
  border-radius: 10px;
  border: 1px solid rgba(106, 27, 154, 0.25);
}

@media (max-width: 600px) {
  .dojo-inline-block {
    flex-direction: column !important;
  }
  .dojo-inline-imgs img {
    width: 100%;
    max-width: 300px;
  }
}

/* ==========================================================================
   Dojo event block (Bild oben, Text darunter)
   ========================================================================== */

.dojo-event-block {
  margin-top: 1.25rem;
}

.dojo-event-img {
  width: 55%;
  max-width: 500px;
  border-radius: 10px;
  border: 1px solid rgba(106, 27, 154, 0.25);
  margin-bottom: 0.75rem;
}

.dojo-event-block p {
  margin: 0 0 0.75rem;
  line-height: 1.65;
  color: #e7e7e7;
}

.dojo-event-block p:last-child {
  margin-bottom: 0;
}

@media (max-width: 600px) {
  .dojo-event-img {
    width: 100%;
    max-width: 100%;
  }
}
