/* KGame portal — k-gm.beauty */
:root {
  --bg: #071422;
  --bg-soft: #0b1c31;
  --surface: #102641;
  --surface-2: #163353;
  --line: rgba(125, 188, 230, 0.16);
  --text: #e9f3fb;
  --muted: #92acc2;
  --accent: #1ec8b0;
  --accent-2: #3aa7ff;
  --gold: #e2b34a;
  --danger: #ff6b6b;
  --radius: 14px;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  --nav-h: 72px;
  --max: 1180px;
  --font-display: "Sora", "Be Vietnam Pro", sans-serif;
  --font-body: "Be Vietnam Pro", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(30, 200, 176, 0.12), transparent 55%),
    radial-gradient(900px 500px at 90% 0%, rgba(58, 167, 255, 0.1), transparent 50%),
    linear-gradient(180deg, #06101c 0%, var(--bg) 35%, #081828 100%);
  background-attachment: fixed;
  line-height: 1.65;
  min-height: 100vh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent-2);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
  color: var(--accent);
}

ul,
ol {
  padding-left: 1.2rem;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.25;
  margin: 0 0 0.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(1.75rem, 3.4vw, 2.6rem);
}

h2 {
  font-size: clamp(1.35rem, 2.4vw, 1.9rem);
}

h3 {
  font-size: 1.15rem;
}

p {
  margin: 0 0 1rem;
  color: var(--muted);
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: #042018;
  padding: 0.6rem 1rem;
  z-index: 10000;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--nav-h);
  backdrop-filter: blur(14px);
  background: rgba(7, 20, 34, 0.88);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 1;
  min-width: 0;
  max-width: min(200px, 46vw);
  height: 100%;
  overflow: hidden;
}

.brand img {
  height: 36px;
  max-height: calc(var(--nav-h) - 24px);
  width: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: left center;
}

.brand-text {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-left: auto;
}

.nav-desktop {
  display: none;
  align-items: center;
  gap: 0.35rem;
}

.nav-desktop a {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
}

.nav-desktop a:hover,
.nav-desktop a.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.auth-desktop {
  display: none;
  gap: 0.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 0;
  border-radius: 10px;
  padding: 0.7rem 1.15rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #129d8c);
  color: #042018;
  box-shadow: 0 8px 24px rgba(30, 200, 176, 0.28);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}

.btn-outline:hover {
  border-color: var(--accent-2);
  color: var(--accent-2);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.menu-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 10px;
  padding: 0.55rem 0.8rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
}

.menu-toggle svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.mobile-panel {
  display: none;
  position: absolute;
  top: var(--nav-h);
  left: 0;
  right: 0;
  background: rgba(8, 22, 38, 0.98);
  border-bottom: 1px solid var(--line);
  padding: 1rem 0 1.25rem;
  box-shadow: var(--shadow);
}

.mobile-panel.open {
  display: block;
  animation: slideDown 0.22s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-panel a {
  display: block;
  color: var(--text);
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-weight: 500;
}

.mobile-auth {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin-top: 1rem;
}

.mobile-auth .btn {
  width: 100%;
}

@media (min-width: 960px) {
  .nav-desktop,
  .auth-desktop {
    display: flex;
  }

  .menu-toggle,
  .mobile-panel {
    display: none !important;
  }
}

/* Hero */
.hero {
  position: relative;
  min-height: min(72vh, 620px);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  isolation: isolate;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  animation: heroZoom 18s ease-in-out infinite alternate;
}

@keyframes heroZoom {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.06);
  }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(6, 16, 28, 0.35) 0%, rgba(6, 16, 28, 0.72) 55%, rgba(6, 16, 28, 0.96) 100%),
    linear-gradient(90deg, rgba(6, 16, 28, 0.75) 0%, rgba(6, 16, 28, 0.25) 55%, transparent 100%);
}

.hero-content {
  padding: 4.5rem 0 3rem;
  max-width: 720px;
}

.hero-content .brand-mark {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.55rem;
  letter-spacing: 0.02em;
  text-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
  animation: fadeUp 0.7s ease both;
}

.hero-content h1 {
  color: #fff;
  margin-bottom: 0.85rem;
  animation: fadeUp 0.7s ease 0.08s both;
}

.hero-content p {
  color: rgba(233, 243, 251, 0.86);
  font-size: 1.05rem;
  max-width: 38rem;
  animation: fadeUp 0.7s ease 0.16s both;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.4rem;
  animation: fadeUp 0.7s ease 0.24s both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sections */
.section {
  padding: 3.5rem 0;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
}

.section-head p {
  margin: 0;
  max-width: 36rem;
}

.eyebrow {
  display: inline-block;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.45rem;
}

.prose {
  max-width: 720px;
}

.prose a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.panel {
  background: linear-gradient(180deg, rgba(22, 51, 83, 0.45), rgba(16, 38, 65, 0.65));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.split {
  display: grid;
  gap: 1.5rem;
  align-items: center;
}

@media (min-width: 860px) {
  .split {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 2rem;
  }

  .split.reverse {
    grid-template-columns: 0.9fr 1.1fr;
  }

  .split.reverse .split-media {
    order: -1;
  }
}

.split-media {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
}

.split-media img {
  width: 100%;
  height: auto;
}

/* Category grid */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
}

@media (min-width: 700px) {
  .cat-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 980px) {
  .cat-grid {
    grid-template-columns: repeat(6, 1fr);
  }
}

.cat-item {
  position: relative;
  display: block;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
  aspect-ratio: 3 / 4;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.cat-item:hover {
  transform: translateY(-4px);
  border-color: rgba(30, 200, 176, 0.45);
}

.cat-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cat-item span {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.4rem 0.7rem 0.7rem;
  background: linear-gradient(transparent, rgba(4, 14, 24, 0.92));
  color: #fff;
  font-weight: 600;
  font-size: 0.88rem;
  text-align: center;
}

/* Cards / articles */
.card-grid {
  display: grid;
  gap: 1.1rem;
}

@media (min-width: 700px) {
  .card-grid.cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .card-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.article-card {
  display: flex;
  flex-direction: column;
  background: rgba(16, 38, 65, 0.72);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease;
  height: 100%;
}

.article-card:hover {
  transform: translateY(-4px);
  border-color: rgba(58, 167, 255, 0.4);
}

.article-card .thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--surface-2);
}

.article-card .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.article-card:hover .thumb img {
  transform: scale(1.05);
}

.article-card .body {
  padding: 1.05rem 1.1rem 1.2rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.article-card .meta {
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 0.45rem;
}

.article-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.article-card h3 a {
  color: var(--text);
}

.article-card h3 a:hover {
  color: var(--accent);
}

.article-card p {
  font-size: 0.92rem;
  margin-bottom: 0.9rem;
  flex: 1;
}

.article-card .more {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--accent-2);
}

/* FAQ */
.faq-list {
  display: grid;
  gap: 0.75rem;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(16, 38, 65, 0.55);
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  padding: 1rem 1.15rem;
  font-weight: 600;
  color: var(--text);
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  float: right;
  color: var(--accent);
  font-weight: 700;
}

.faq-item[open] summary::after {
  content: "–";
}

.faq-item .faq-a {
  padding: 0 1.15rem 1.1rem;
  color: var(--muted);
}

/* Page chrome */
.page-hero {
  padding: 2.4rem 0 1.4rem;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(30, 200, 176, 0.08), transparent),
    rgba(8, 22, 38, 0.4);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  font-size: 0.86rem;
  color: var(--muted);
  margin-bottom: 0.9rem;
}

.breadcrumb a {
  color: var(--muted);
}

.breadcrumb a:hover {
  color: var(--accent);
}

.breadcrumb span {
  opacity: 0.5;
}

.article-layout {
  display: grid;
  gap: 2rem;
  padding: 2.2rem 0 3.5rem;
}

@media (min-width: 960px) {
  .article-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
  }
}

.article-main {
  background: rgba(16, 38, 65, 0.45);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem 1.25rem 1.8rem;
}

@media (min-width: 700px) {
  .article-main {
    padding: 1.8rem 2rem 2.2rem;
  }
}

.article-cover {
  border-radius: 12px;
  overflow: hidden;
  margin: 0 0 1.4rem;
  border: 1px solid var(--line);
}

.article-cover img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 1.2rem;
}

.sidebar .widget {
  background: rgba(16, 38, 65, 0.55);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem;
  margin-bottom: 1rem;
}

.sidebar .widget h3 {
  font-size: 1rem;
  margin-bottom: 0.85rem;
}

.related-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.85rem;
}

.related-list a {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 0.7rem;
  align-items: center;
  color: var(--text);
}

.related-list img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 8px;
}

.related-list span {
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.35;
}

/* Brands */
.brand-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  align-items: center;
}

@media (min-width: 800px) {
  .brand-row {
    grid-template-columns: repeat(8, 1fr);
  }
}

.brand-row img {
  width: 100%;
  height: 48px;
  object-fit: contain;
  filter: grayscale(0.2) brightness(1.05);
  opacity: 0.9;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  padding: 0.4rem;
  border: 1px solid var(--line);
}

/* Error pages */
.error-page {
  min-height: calc(100vh - var(--nav-h) - 220px);
  display: grid;
  place-items: center;
  text-align: center;
  padding: 3rem 0;
}

.error-page .code {
  font-family: var(--font-display);
  font-size: clamp(4rem, 12vw, 7rem);
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1;
  margin-bottom: 0.5rem;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  background: #050f1b;
  padding: 2.8rem 0 1.5rem;
  margin-top: 1rem;
}

.footer-grid {
  display: grid;
  gap: 1.75rem;
}

@media (min-width: 800px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
}

.site-footer h3 {
  font-size: 1rem;
  margin-bottom: 0.85rem;
}

.site-footer p,
.site-footer a {
  color: var(--muted);
  font-size: 0.92rem;
}

.site-footer a:hover {
  color: var(--accent);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.45rem;
}

.footer-bottom {
  margin-top: 2rem;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: space-between;
}

/* Utilities */
.tag {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: rgba(30, 200, 176, 0.12);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
}

.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}
