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

html {
  scroll-behavior: smooth;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
  background: var(--bg-main);
  color: var(--text-main);
  line-height: 1.7;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main {
  width: min(1100px, 92vw);
  margin: 0 auto;
  padding: 5rem 0 4rem;
}

:root {
  --bg-main: #fafbff;
  --bg-elevated: #ffffff;
  --accent-1: #b7aef2;
  --accent-2: #9ecbff;
  --accent-3: #ffd9ec;
  --text-main: #222222;
  --text-muted: #666666;
  --border-soft: #e4e6f5;
  --shadow-soft: 0 14px 40px rgba(15, 23, 42, 0.08);
  --radius-lg: 18px;
  --radius-md: 12px;
}

body[data-page="anime"] {
  --bg-main: #fdf4ff;
  --bg-elevated: #ffffff;
  --accent-1: #fb7185;
  --accent-2: #6366f1;
  --accent-3: #f9a8d4;
  --text-main: #1f2933;
  --text-muted: #6b7280;
  --border-soft: #f5d0fe;
}

body[data-page="photography"] {
  --bg-main: #f3f4f6;
  --bg-elevated: #ffffff;
  --border-soft: #d1d5db;
}

body.theme-gulf {
  --bg-main: #020617;
  --bg-elevated: #0b1120;
  --accent-1: #69c3ff;
  --accent-2: #ff6a00;
  --accent-3: #f97316;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --border-soft: rgba(148, 163, 184, 0.4);
  --shadow-soft: 0 18px 50px rgba(15, 23, 42, 0.9);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: linear-gradient(
      to bottom,
      rgba(250, 251, 255, 0.92),
      rgba(250, 251, 255, 0.7),
      transparent
    );
  border-bottom: 1px solid rgba(226, 232, 240, 0.7);
}

body.theme-gulf .site-header {
  background: linear-gradient(
      to bottom,
      rgba(15, 23, 42, 0.96),
      rgba(15, 23, 42, 0.82),
      transparent
    );
  border-bottom-color: rgba(30, 64, 175, 0.5);
}

.nav-inner {
  width: min(1100px, 92vw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 0;
}

.logo {
  font-weight: 700;
  letter-spacing: 0.14em;
  font-size: 0.85rem;
  text-transform: uppercase;
  color: var(--accent-1);
}

.nav-links {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-link {
  font-size: 0.86rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  text-decoration: none;
  color: var(--text-muted);
  border: 1px solid transparent;
  transition: all 0.18s ease-out;
}

.nav-link:hover {
  color: var(--text-main);
  background: rgba(183, 174, 242, 0.1);
  border-color: rgba(148, 163, 184, 0.4);
  transform: translateY(-1px);
}

body.theme-gulf .nav-link:hover {
  background: rgba(105, 195, 255, 0.08);
  color: var(--text-main);
}

.nav-link.active {
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 10px 28px rgba(148, 163, 255, 0.6);
}

.hero {
  position: relative;
  padding: 6rem 0 4.5rem;
  width: min(1100px, 92vw);
  margin: 0 auto;
  display: grid;
  gap: 3rem;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  align-items: center;
}

.hero-bg {
  position: fixed;
  inset: 0;
  z-index: -10;
  background:
    radial-gradient(circle at top left, rgba(183, 174, 242, 0.45), transparent 55%),
    radial-gradient(circle at bottom right, rgba(158, 203, 255, 0.4), transparent 55%),
    radial-gradient(circle at center, rgba(255, 217, 236, 0.25), transparent 60%),
    linear-gradient(to bottom, #f8fafc, #faf5ff);
  pointer-events: none;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
    130deg,
    rgba(255, 255, 255, 0.1) 0,
    transparent 35%,
    transparent 65%,
    rgba(255, 255, 255, 0.15) 100%
  );
  mix-blend-mode: screen;
  opacity: 0.6;
}

body.theme-gulf .hero-bg {
  display: none;
}

.hero-main-title {
  font-size: clamp(2.4rem, 4vw, 3.1rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.75rem;
}

.hero-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 30rem;
}

.hero-tagline {
  margin-top: 1.2rem;
  font-size: 1rem;
}

.hero-tagline span.words {
  font-weight: 600;
  color: var(--accent-1);
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1.2rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.9rem;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.18s ease-out;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
  color: #ffffff;
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
  transform: translateY(-1px) scale(1.01);
  box-shadow: 0 20px 40px rgba(148, 163, 255, 0.45);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.8);
  border-color: var(--border-soft);
  color: var(--text-muted);
}

.btn-ghost:hover {
  background: #ffffff;
  color: var(--text-main);
}

.hero-sidecard {
  background: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  padding: 1.4rem 1.3rem;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
  animation: floatCard 8s ease-in-out infinite alternate;
}

.hero-sidecard::before {
  content: "";
  position: absolute;
  inset: -40%;
  background:
    radial-gradient(circle at 0% 0%, rgba(183, 174, 242, 0.18), transparent 50%),
    radial-gradient(circle at 100% 100%, rgba(158, 203, 255, 0.18), transparent 50%);
  opacity: 0.7;
  pointer-events: none;
}

.hero-sidecard-content {
  position: relative;
  z-index: 1;
}

.hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  background: rgba(248, 250, 252, 0.9);
  border: 1px solid rgba(209, 213, 219, 0.9);
  margin-bottom: 0.7rem;
}

.hero-chip-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
}

.hero-sidecard p {
  font-size: 0.86rem;
  color: var(--text-muted);
}

@keyframes floatCard {
  from {
    transform: translateY(0px);
  }
  to {
    transform: translateY(-6px);
  }
}

.section {
  margin-bottom: 3.5rem;
}

.section-heading {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.section-subtitle {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin-bottom: 1.6rem;
}

.grid {
  display: grid;
  gap: 1.2rem;
}

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

.card {
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  padding: 1rem 1.1rem;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.04);
  transition: transform 0.18s ease-out, box-shadow 0.18s ease-out, border-color 0.18s;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-soft);
  border-color: rgba(148, 163, 255, 0.6);
}

body[data-page="anime"] .card {
  border-radius: 16px;
  border: 1px solid rgba(244, 114, 182, 0.5);
  box-shadow: 0 18px 40px rgba(244, 114, 182, 0.18);
}

body[data-page="anime"] .card:hover {
  border-color: rgba(129, 140, 248, 0.9);
  box-shadow: 0 24px 60px rgba(129, 140, 248, 0.35);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.masonry {
  column-count: 3;
  column-gap: 0.8rem;
}

.masonry-item {
  break-inside: avoid;
  margin-bottom: 0.8rem;
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
}

.masonry-item img {
  width: 100%;
  display: block;
  transition: transform 0.4s ease-out;
}

.masonry-item:hover img {
  transform: scale(1.04);
}

.masonry-caption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 0.35rem 0.6rem 0.5rem;
  font-size: 0.75rem;
  color: #f9fafb;
  background: linear-gradient(to top, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0));
}

@media (max-width: 900px) {
  .masonry {
    column-count: 2;
  }
}

@media (max-width: 600px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
    padding-top: 4.5rem;
  }
  .masonry {
    column-count: 1;
  }
}

.lightbox-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 80;
}

.lightbox-img {
  max-width: 92vw;
  max-height: 86vh;
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.8);
}

.lightbox-close {
  position: fixed;
  top: 1.4rem;
  right: 1.4rem;
  font-size: 2rem;
  color: #e5e7eb;
  cursor: pointer;
}

.timeline {
  border-left: 2px solid var(--border-soft);
  padding-left: 1.4rem;
  margin-left: 0.4rem;
}

.timeline-item {
  position: relative;
  margin-bottom: 1.4rem;
}

.timeline-dot {
  position: absolute;
  left: -1.45rem;
  top: 0.3rem;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
}

.timeline-year {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
}

.timeline-title {
  font-weight: 600;
  margin-top: 0.1rem;
}

.timeline-body {
  font-size: 0.87rem;
  color: var(--text-muted);
}

.travel-line {
  display: flex;
  overflow-x: auto;
  gap: 1.5rem;
  padding-bottom: 0.4rem;
}

.travel-card {
  min-width: 180px;
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  padding: 0.8rem 0.9rem;
  border: 1px dashed var(--border-soft);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
  flex-shrink: 0;
}

.travel-card h4 {
  font-size: 0.9rem;
}

body.theme-gulf .main {
  padding-top: 5rem;
}

.gulf-hero {
  background: radial-gradient(circle at top left, #69c3ff, #0b1120);
  border-radius: 24px;
  border: 1px solid #1d4ed8;
  padding: 1.6rem 1.5rem;
  box-shadow: 0 26px 70px rgba(15, 23, 42, 0.9);
  position: relative;
  overflow: hidden;
  color: #eff6ff;
  margin-bottom: 2rem;
}

.gulf-stripe {
  position: absolute;
  inset: -40%;
  background: linear-gradient(
    120deg,
    transparent 0%,
    rgba(255, 106, 0, 0.7) 42%,
    rgba(249, 115, 22, 0.95) 52%,
    rgba(255, 106, 0, 0.8) 62%,
    transparent 100%
  );
  transform: rotate(-12deg);
  mix-blend-mode: screen;
  pointer-events: none;
  opacity: 0.9;
}

.gulf-hero-content {
  position: relative;
  z-index: 1;
}

/* — Steam Profile Embed Card — */
.steam-embed-container {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
}

.steam-embed {
  width: 350px;
  height: 230px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-elevated);
  border: none;
}

/* Mobile adjustments: shrink height */
@media (max-width: 500px) {
  .steam-embed {
    height: 300px;
  }
}

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

.game-card {
  background: radial-gradient(circle at top, rgba(15, 23, 42, 0.98), #020617);
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  padding: 0.6rem;
  box-shadow: 0 22px 50px rgba(15, 23, 42, 0.9);
  overflow: hidden;
  transition: transform 0.18s ease-out, box-shadow 0.18s ease-out, border-color 0.18s;
}

.game-card:hover {
  transform: translateY(-4px) scale(1.01);
  border-color: rgba(105, 195, 255, 0.9);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.9);
}

.game-card img {
  width: 100%;
  display: block;
  border-radius: 12px;
  margin-bottom: 0.5rem;
}

.footer {
  margin-top: auto;
  padding: 1.4rem 0 1.8rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}
