/* =============================================================
   HIDDEN LEAF VILLAGE — Naruto Fan Community
   Dark cinematic theme: navy/black backgrounds, orange + cyan accents
   ============================================================= */

/* ---------------------------------------------------------------
   CSS CUSTOM PROPERTIES
   --------------------------------------------------------------- */
:root {
  --bg-base:        #070b16;
  --bg-surface:     #0d1426;
  --bg-card:        #111827;
  --bg-card-hover:  #161f34;
  --bg-border:      #1e2d47;

  --accent-orange:  #FF6B00;
  --accent-orange-dim: #cc5500;
  --accent-cyan:    #00D4FF;
  --accent-cyan-dim: #0099bb;

  --text-primary:   #f0f4ff;
  --text-secondary: #8b9ab5;
  --text-muted:     #4a5568;

  --font-display:   'Cinzel', Georgia, serif;
  --font-body:      'Inter', system-ui, -apple-system, sans-serif;

  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  16px;
  --radius-xl:  24px;

  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 40px rgba(255, 107, 0, 0.2);

  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  --max-w: 1200px;
  --section-py: 100px;
}

/* ---------------------------------------------------------------
   RESET & BASE
   --------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.7;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

details {
  list-style: none;
}

details summary {
  cursor: pointer;
  list-style: none;
}

details summary::-webkit-details-marker {
  display: none;
}

/* ---------------------------------------------------------------
   ACCENT UTILITY
   --------------------------------------------------------------- */
.accent {
  color: var(--accent-orange);
}

/* ---------------------------------------------------------------
   SECTION SHARED
   --------------------------------------------------------------- */
.section-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--section-py) 24px;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-orange);
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.section-desc {
  max-width: 600px;
  margin: 0 auto;
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.8;
}

/* ---------------------------------------------------------------
   BUTTONS
   --------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent-orange);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-orange-dim);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 107, 0, 0.35);
}

.btn-ghost {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--bg-border);
}

.btn-ghost:hover {
  border-color: var(--accent-orange);
  color: var(--accent-orange);
  transform: translateY(-2px);
}

/* ---------------------------------------------------------------
   TAGS
   --------------------------------------------------------------- */
.tag {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  background: rgba(255, 107, 0, 0.1);
  color: var(--accent-orange);
  border: 1px solid rgba(255, 107, 0, 0.25);
}

/* ---------------------------------------------------------------
   SCROLL REVEAL
   --------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ---------------------------------------------------------------
   HEADER / NAV
   --------------------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 24px;
  height: 70px;
  display: flex;
  align-items: center;
  transition: background var(--transition), backdrop-filter var(--transition), border-color var(--transition);
  border-bottom: 1px solid transparent;
}

.site-header.scrolled {
  background: rgba(7, 11, 22, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--bg-border);
}

.nav-inner {
  max-width: var(--max-w);
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo-icon {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--text-primary);
  white-space: nowrap;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition);
}

.nav-link:hover {
  color: var(--text-primary);
}

.nav-cta {
  margin-left: 8px;
  padding: 9px 20px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  background: var(--accent-orange);
  color: #fff;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}

.nav-cta:hover {
  background: var(--accent-orange-dim);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(255, 107, 0, 0.3);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 32px;
  height: 32px;
  justify-content: center;
  align-items: center;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

/* ---------------------------------------------------------------
   HERO
   --------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

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

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    rgba(7, 11, 22, 0.92) 0%,
    rgba(7, 11, 22, 0.7) 50%,
    rgba(7, 11, 22, 0.4) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 120px 24px 80px;
  width: 100%;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 100px;
  background: rgba(255, 107, 0, 0.1);
  border: 1px solid rgba(255, 107, 0, 0.3);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-orange);
  margin-bottom: 24px;
  animation: fadeSlideUp 0.8s ease 0.2s both;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-orange);
  animation: pulse 2s ease-in-out infinite;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 7rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  animation: fadeSlideUp 0.8s ease 0.35s both;
}

.hero-title-line {
  display: block;
}

.hero-subtitle {
  max-width: 520px;
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: rgba(240, 244, 255, 0.75);
  line-height: 1.8;
  margin-bottom: 36px;
  animation: fadeSlideUp 0.8s ease 0.5s both;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 60px;
  animation: fadeSlideUp 0.8s ease 0.65s both;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 28px;
  animation: fadeSlideUp 0.8s ease 0.8s both;
}

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

.stat-num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 900;
  color: var(--accent-orange);
  line-height: 1;
}

.stat-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--bg-border);
}

.hero-scroll-hint {
  position: absolute;
  bottom: 32px;
  right: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0.5;
  animation: fadeSlideUp 0.8s ease 1.2s both;
}

.hero-scroll-hint span {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
}

.scroll-line {
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, var(--accent-orange), transparent);
  animation: scrollLine 2s ease-in-out infinite;
}

/* ---------------------------------------------------------------
   CHARACTERS
   --------------------------------------------------------------- */
.characters {
  background: var(--bg-surface);
  position: relative;
}

.characters::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-orange), transparent);
  opacity: 0.4;
}

.characters-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 48px;
}

.char-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.char-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-card), 0 0 30px rgba(255, 107, 0, 0.15);
  border-color: rgba(255, 107, 0, 0.4);
}

.char-card--featured {
  border-color: rgba(255, 107, 0, 0.3);
  position: relative;
}

.char-card--featured::after {
  content: 'Rival';
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--accent-orange);
  color: #fff;
  z-index: 2;
}

.char-img-wrap {
  position: relative;
  height: 300px;
  overflow: hidden;
}

.char-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform 0.6s ease;
}

.char-card:hover .char-img {
  transform: scale(1.05);
}

.char-img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, var(--bg-card) 0%, transparent 60%);
}

.char-info {
  padding: 24px;
}

.char-rank {
  margin-bottom: 10px;
}

.rank-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(255, 107, 0, 0.12);
  color: var(--accent-orange);
  border: 1px solid rgba(255, 107, 0, 0.3);
}

.rank-badge--blue {
  background: rgba(0, 212, 255, 0.1);
  color: var(--accent-cyan);
  border-color: rgba(0, 212, 255, 0.3);
}

.char-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.2;
}

.char-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 16px;
}

.char-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* Team 7 Banner */
.team7-banner {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: 280px;
  border: 1px solid var(--bg-border);
}

.team7-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
}

.team7-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(7, 11, 22, 0.85) 0%, rgba(7, 11, 22, 0.3) 100%);
  display: flex;
  align-items: flex-end;
  padding: 28px 32px;
}

.team7-label {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.04em;
}

/* ---------------------------------------------------------------
   ARCS
   --------------------------------------------------------------- */
.arcs {
  background: var(--bg-base);
  position: relative;
}

.arcs::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--bg-border), transparent);
}

.arcs-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.arc-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color var(--transition);
}

.arc-card[open] {
  border-color: rgba(255, 107, 0, 0.35);
}

.arc-summary {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 24px 28px;
  user-select: none;
  transition: background var(--transition);
}

.arc-summary:hover {
  background: var(--bg-card-hover);
}

.arc-card[open] .arc-summary {
  border-bottom: 1px solid var(--bg-border);
}

.arc-num {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--bg-border);
  line-height: 1;
  min-width: 52px;
  transition: color var(--transition);
}

.arc-card[open] .arc-num {
  color: var(--accent-orange);
}

.arc-head {
  flex: 1;
  min-width: 0;
}

.arc-title {
  font-family: var(--font-display);
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  font-weight: 700;
  margin-bottom: 4px;
  line-height: 1.2;
}

.arc-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

.arc-chevron {
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
  flex-shrink: 0;
  transition: transform var(--transition), color var(--transition);
}

.arc-card[open] .arc-chevron {
  transform: rotate(180deg);
  color: var(--accent-orange);
}

.arc-body {
  padding: 24px 28px;
  padding-left: calc(28px + 52px + 20px);
}

.arc-body p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px;
}

.arc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* ---------------------------------------------------------------
   COMMUNITY
   --------------------------------------------------------------- */
.community {
  position: relative;
  overflow: hidden;
}

.community-bg-img {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.community-bg-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  filter: brightness(0.25) saturate(0.5);
}

.community-bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(7, 11, 22, 0.85) 0%, rgba(13, 20, 38, 0.75) 100%);
}

.community-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.community-content .section-header {
  text-align: left;
  margin-bottom: 32px;
}

.community-content .section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
}

.community-content .section-desc {
  max-width: none;
  margin: 0;
  margin-bottom: 32px;
}

.community-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.community-cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.comm-card {
  background: rgba(13, 20, 38, 0.8);
  border: 1px solid var(--bg-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  align-items: flex-start;
  gap: 18px;
  backdrop-filter: blur(8px);
  transition: border-color var(--transition), transform var(--transition);
}

.comm-card:hover {
  border-color: rgba(255, 107, 0, 0.4);
  transform: translateX(6px);
}

.comm-card-icon {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: var(--radius-md);
  background: rgba(255, 107, 0, 0.1);
  border: 1px solid rgba(255, 107, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-orange);
}

.comm-card-icon svg {
  width: 20px;
  height: 20px;
}

.comm-card-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.comm-card-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---------------------------------------------------------------
   FOOTER
   --------------------------------------------------------------- */
.site-footer {
  background: var(--bg-surface);
  border-top: 1px solid var(--bg-border);
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 64px 24px 40px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}

.footer-brand .logo {
  margin-bottom: 14px;
}

.footer-tagline {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 280px;
}

.footer-heading {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-secondary);
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--accent-orange);
}

.footer-bottom {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 20px 24px;
  border-top: 1px solid var(--bg-border);
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ---------------------------------------------------------------
   ANIMATIONS
   --------------------------------------------------------------- */
@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

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

@keyframes scrollLine {
  0%   { transform: scaleY(0); transform-origin: top; }
  50%  { transform: scaleY(1); transform-origin: top; }
  51%  { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ---------------------------------------------------------------
   RESPONSIVE
   --------------------------------------------------------------- */
@media (max-width: 1024px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .community-inner {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .community-content .section-header {
    text-align: center;
  }

  .community-content .section-desc {
    text-align: center;
  }

  .community-actions {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  :root {
    --section-py: 64px;
  }

  .nav-links {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    background: rgba(7, 11, 22, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    gap: 4px;
    border-bottom: 1px solid var(--bg-border);
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.35s ease, opacity 0.35s ease;
    z-index: 99;
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .nav-link, .nav-cta {
    padding: 14px 16px;
    border-radius: var(--radius-md);
    text-align: center;
  }

  .nav-cta {
    margin-left: 0;
    text-align: center;
  }

  .nav-toggle {
    display: flex;
  }

  .characters-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .char-img-wrap {
    height: 260px;
  }

  .hero-stats {
    gap: 20px;
  }

  .stat-num {
    font-size: 1.6rem;
  }

  .hero-scroll-hint {
    display: none;
  }

  .arc-summary {
    padding: 18px 20px;
    gap: 14px;
  }

  .arc-num {
    font-size: 1.8rem;
    min-width: 36px;
  }

  .arc-body {
    padding: 20px;
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .team7-banner {
    height: 200px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: clamp(2.4rem, 10vw, 4rem);
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    justify-content: center;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    gap: 16px;
  }

  .stat-divider {
    height: 30px;
  }

  .community-inner {
    padding-top: 48px;
    padding-bottom: 48px;
  }

  .arc-body {
    padding-left: 20px;
  }
}
