/* ========================================================================
   Base Stylesheet – monochromedepths.com
   Dark, monochrome, cinematic, minimalistic
   ======================================================================== */

/* ========================================================================
   1. CSS CUSTOM PROPERTIES (VARIABLES)
   ======================================================================== */
:root {
  /* Color palette – deep-sea monochrome */
  --color-bg: #05070a;                /* primary background – deep abyss */
  --color-bg-elevated: #0b0f16;       /* cards, panels */
  --color-bg-alt: #080b11;            /* subtle section contrast */

  --color-text: #e4e7ec;              /* primary text */
  --color-text-muted: #a0a7b5;        /* secondary text */
  --color-border-subtle: #1b202a;     /* hairline borders */

  --color-primary: #c5f5ff;           /* accent – cold cyan highlight */
  --color-primary-soft: rgba(121, 212, 255, 0.08);

  --color-success: #4ade80;           /* subtle positive state */
  --color-warning: #facc15;
  --color-danger: #fb7185;

  /* Neutral grays (for flexible UI use) */
  --gray-50:  #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2933;
  --gray-900: #111827;

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "IBM Plex Sans", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo,
    Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  /* Font sizes – fluid-ish scale tuned for cinematic headings */
  --text-xs: 0.75rem;   /* 12px */
  --text-sm: 0.875rem;  /* 14px */
  --text-md: 1rem;      /* 16px */
  --text-lg: 1.125rem;  /* 18px */
  --text-xl: 1.25rem;   /* 20px */
  --text-2xl: 1.5rem;   /* 24px */
  --text-3xl: 1.875rem; /* 30px */
  --text-4xl: 2.25rem;  /* 36px */
  --text-5xl: 3rem;     /* 48px */

  /* Line heights */
  --leading-tight: 1.2;
  --leading-snug: 1.35;
  --leading-normal: 1.5;
  --leading-relaxed: 1.7;

  /* Spacing scale (0–96px) */
  --space-0: 0;
  --space-1: 0.25rem;  /* 4px */
  --space-2: 0.5rem;   /* 8px */
  --space-3: 0.75rem;  /* 12px */
  --space-4: 1rem;     /* 16px */
  --space-5: 1.25rem;  /* 20px */
  --space-6: 1.5rem;   /* 24px */
  --space-8: 2rem;     /* 32px */
  --space-10: 2.5rem;  /* 40px */
  --space-12: 3rem;    /* 48px */
  --space-16: 4rem;    /* 64px */
  --space-20: 5rem;    /* 80px */
  --space-24: 6rem;    /* 96px */

  /* Radius */
  --radius-sm: 0.25rem;  /* 4px */
  --radius-md: 0.5rem;   /* 8px */
  --radius-lg: 0.75rem;  /* 12px */
  --radius-xl: 1.25rem;  /* 20px – for cinematic cards */
  --radius-full: 999px;

  /* Shadows – soft, directional, underwater feel */
  --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.7);
  --shadow-subtle: 0 12px 25px rgba(0, 0, 0, 0.55);
  --shadow-focus: 0 0 0 1px rgba(197, 245, 255, 0.6),
                  0 0 0 6px rgba(121, 212, 255, 0.25);

  /* Transitions */
  --transition-fast: 120ms ease-out;
  --transition-normal: 200ms ease-out;
  --transition-slow: 320ms ease-out;

  /* Layout */
  --container-max: 1160px;
  --container-padding-x: 1.5rem;
}

/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
  :root {
    --transition-fast: 0ms;
    --transition-normal: 0ms;
    --transition-slow: 0ms;
  }

  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ========================================================================
   2. RESET / NORMALIZE
   ======================================================================== */

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

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  min-height: 100vh;
}

img,
video,
canvas,
svg,
picture {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  border: none;
  padding: 0;
  background: none;
}

ul[class],
ol[class] {
  padding: 0;
  margin: 0;
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6,
p,
figure,
blockquote,
dl,
dd {
  margin: 0;
}

/* ========================================================================
   3. BASE TYPOGRAPHY & LAYOUT
   ======================================================================== */

body {
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
  background-color: var(--color-bg);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main {
  min-height: 60vh;
}

/* Headings – cinematic, tight, minimal spacing */

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: var(--leading-tight);
  letter-spacing: 0.02em;
  color: var(--color-text);
}

h1 {
  font-size: clamp(2.5rem, 4vw, var(--text-5xl));
  margin-bottom: var(--space-4);
}

h2 {
  font-size: clamp(1.75rem, 2.4vw, var(--text-3xl));
  margin-bottom: var(--space-3);
}

h3 {
  font-size: clamp(1.35rem, 1.8vw, var(--text-2xl));
  margin-bottom: var(--space-2);
}

h4 {
  font-size: var(--text-xl);
  margin-bottom: var(--space-2);
}

p {
  margin-bottom: var(--space-4);
  color: var(--color-text-muted);
}

strong {
  color: var(--color-text);
  font-weight: 600;
}

/* Links – minimal, glow on hover */

a {
  color: var(--color-primary);
  text-decoration: none;
  cursor: pointer;
  transition: color var(--transition-normal),
              text-decoration-color var(--transition-normal),
              opacity var(--transition-fast);
}

a:hover {
  opacity: 0.9;
}

a:active {
  opacity: 0.8;
}

/* Highlight for CTA-like links (e.g., Google Play button in nav) */
.a-cta {
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Lists (non-utility) */

ul,
ol {
  padding-left: 1.5rem;
  margin-bottom: var(--space-4);
}


/* Code / pre (for technical blog sections) */

code,
pre {
  font-family: var(--font-mono);
}

pre {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background-color: #050608;
  border: 1px solid var(--color-border-subtle);
  overflow-x: auto;
}

/* ========================================================================
   4. ACCESSIBILITY & FOCUS STYLES
   ======================================================================== */

:focus-visible {
  outline: none;
}

/* Global focus rings for interactive elements */

a[href],
button,
input,
textarea,
select,
[tabindex]:not([tabindex="-1"]) {
  outline: none;
}

a[href]:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible {
  box-shadow: var(--shadow-focus);
  border-color: transparent;
}

/* Screen reader only utility */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ========================================================================
   5. UTILITIES – LAYOUT & STRUCTURE
   ======================================================================== */

/* Container */

.container {
  width: 100%;
  /*max-width: var(--container-max);*/
  max-width: 1250px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding-x);
  padding-right: var(--container-padding-x);
}

.section {
  padding-top: var(--space-12);
  padding-bottom: var(--space-12);
}

.section--tight {
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
}

.section--alt {
  background: radial-gradient(circle at top, rgba(197, 245, 255, 0.05), transparent 55%),
              var(--color-bg-alt);
}

/* Flex helpers */

.flex {
  display: flex;
}

.inline-flex {
  display: inline-flex;
}

.flex-col {
  flex-direction: column;
}

.flex-row {
  flex-direction: row;
}

.flex-wrap {
  flex-wrap: wrap;
}

.items-center {
  align-items: center;
}

.items-start {
  align-items: flex-start;
}

.items-end {
  align-items: flex-end;
}

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

.justify-between {
  justify-content: space-between;
}

.gap-2 {
  gap: var(--space-2);
}

.gap-4 {
  gap: var(--space-4);
}

.gap-6 {
  gap: var(--space-6);
}

/* Grid helpers */

.grid {
  display: grid;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
}

@media (max-width: 900px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Alignment & text */

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

.text-right {
  text-align: right;
}

.text-muted {
  color: var(--color-text-muted);
}

/* Spacing utilities (vertical rhythm) */

.mt-0 { margin-top: 0; }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }

.mb-0 { margin-bottom: 0; }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.pt-8 { padding-top: var(--space-8); }
.pb-8 { padding-bottom: var(--space-8); }

/* Max width helpers for text blocks */

.prose-narrow {
  max-width: 52ch;
}

.prose-wide {
  max-width: 70ch;
}

/* ========================================================================
   6. COMPONENTS – BUTTONS, INPUTS, CARDS
   ======================================================================== */

/* Buttons – primary CTA for Google Play & key actions */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8rem 1.75rem;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  background: linear-gradient(135deg, #f9feff, #bdefff);
  color: #020617;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.85);
  transition: transform var(--transition-fast),
              box-shadow var(--transition-fast),
              background var(--transition-normal),
              color var(--transition-normal),
              opacity var(--transition-fast);
}

.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(0, 0, 0, 0.25);
  pointer-events: none;
}

.btn:hover {
  transform: translateY(-1px) scale(1.01);
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.9);
}

.btn:active {
  transform: translateY(0) scale(0.99);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.85);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

/* Dark ghost button, e.g. secondary actions */

.btn--ghost {
  background: rgba(9, 12, 19, 0.85);
  color: var(--color-text);
  border-color: var(--color-border-subtle);
  box-shadow: var(--shadow-subtle);
}

.btn--ghost:hover {
  background: rgba(18, 23, 33, 0.98);
}

/* Outline button – for filters, tabs */

.btn--outline {
  background: transparent;
  color: var(--color-text-muted);
  border-color: rgba(121, 212, 255, 0.4);
  box-shadow: none;
}

.btn--outline:hover {
  background: rgba(121, 212, 255, 0.08);
  color: var(--color-primary);
}

/* Full-width variant */

.btn--block {
  width: 100%;
}

/* Inputs – shared across Kontakt form and other UI */

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: var(--space-4);
}

.field-label {
  font-size: var(--text-sm);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.field-description {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.input,
.textarea,
select {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border-subtle);
  background-color: rgba(5, 7, 10, 0.9);
  color: var(--color-text);
  font-size: var(--text-sm);
  outline: none;
  transition: border-color var(--transition-fast),
              box-shadow var(--transition-fast),
              background-color var(--transition-fast);
}

.input::placeholder,
.textarea::placeholder {
  color: rgba(160, 167, 181, 0.6);
}

.input:focus-visible,
.textarea:focus-visible,
select:focus-visible {
  border-color: rgba(197, 245, 255, 0.7);
  box-shadow: 0 0 0 1px rgba(197, 245, 255, 0.7);
}

.input:disabled,
.textarea:disabled,
select:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.textarea {
  min-height: 140px;
  resize: vertical;
}

/* Cards – for sections like O grze, Świat i stworzenia, Aktualizacje */

.card {
  position: relative;
  padding: var(--space-5);
  border-radius: var(--radius-xl);
  background:
    radial-gradient(circle at top left, rgba(197, 245, 255, 0.14), transparent 55%),
    radial-gradient(circle at bottom right, rgba(0, 0, 0, 0.64), transparent 60%),
    var(--color-bg-elevated);
  border: 1px solid rgba(197, 245, 255, 0.12);
  box-shadow: var(--shadow-subtle);
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: radial-gradient(circle at top, rgba(197, 245, 255, 0.06), transparent 60%);
  opacity: 0.8;
  mix-blend-mode: screen;
  pointer-events: none;
}

.card__header {
  margin-bottom: var(--space-4);
}

.card__title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-2);
}

.card__meta {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-text-muted);
}

.card--ghost {
  background: rgba(4, 7, 12, 0.9);
  border-color: rgba(27, 32, 42, 0.9);
  box-shadow: none;
}

/* ========================================================================
   7. MEDIA PLACEHOLDER STYLES – GAMEPLAY, SCREENSHOTS
   ======================================================================== */

.media-frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background:
    radial-gradient(circle at 20% 0%, rgba(197, 245, 255, 0.12), transparent 55%),
    linear-gradient(145deg, #020617, #020617 40%, #020617 100%);
  border: 1px solid rgba(37, 46, 65, 0.95);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.9);
  min-height: 220px;
}

.media-frame--tall {
  min-height: 320px;
}

.media-frame__label {
  position: absolute;
  bottom: 0.9rem;
  left: 1.1rem;
  padding: 0.28rem 0.7rem;
  border-radius: var(--radius-full);
  background-color: rgba(2, 6, 23, 0.84);
  border: 1px solid rgba(148, 163, 184, 0.65);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  backdrop-filter: blur(12px);
}

/* ========================================================================
   8. GLOBAL PAGE-SPECIFIC HOOKS (OPTIONAL, LIGHTWEIGHT)
   ======================================================================== */

/* Top navigation baseline (used across all pages: Strona główna, O grze, etc.) */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: linear-gradient(to bottom, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.84));
  border-bottom: 1px solid rgba(15, 23, 42, 0.95);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 15px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.site-nav a {
  color: var(--color-text-muted);
  position: relative;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.45rem;
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.8), rgba(197, 245, 255, 1));
  transition: width var(--transition-normal);
}

.site-nav a:hover {
  color: var(--color-primary);
}

.site-nav a:hover::after,
.site-nav a[aria-current="page"]::after {
  width: 100%;
}

.site-nav a[aria-current="page"] {
  color: var(--color-primary);
}

/* Hero section for Strona główna */

.hero {
  padding-top: var(--space-16);
  padding-bottom: var(--space-16);
}

@media (max-width: 768px) {
  .hero {
    padding-top: var(--space-12);
    padding-bottom: var(--space-12);
  }

  .site-nav {
    gap: 1rem;
    font-size: 0.72rem;
  }
}

/* Footer */

.site-footer {
  border-top: 1px solid rgba(15, 23, 42, 0.95);
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  background: radial-gradient(circle at top, rgba(15, 23, 42, 0.9), transparent 60%),
              #020617;
}

.site-footer__split {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  align-items: center;
}

@media (max-width: 640px) {
  .site-footer__split {
    flex-direction: column;
    align-items: flex-start;
  }
}
