/* ==========================================================================
   kevvli community - Główny arkusz stylów
   Stylistyka: PURE DARK / STEALTH BLACK & OBSIDIAN GAMING AESTHETIC
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@400;600;700&family=Press+Start+2P&display=swap');

:root {
  --kevvli-black: #000000;
  --kevvli-bg: #050507;
  --kevvli-surface: #0a0b0f;
  --kevvli-card: #0e0f14;
  --kevvli-card-hover: #13141b;
  --kevvli-border: rgba(255, 255, 255, 0.07);
  --kevvli-border-hover: rgba(255, 255, 255, 0.18);
  
  --mc-emerald: #10b981;
  --mc-emerald-glow: rgba(16, 185, 129, 0.2);
  --mc-dark-glow: rgba(255, 255, 255, 0.05);
}

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

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--kevvli-black);
  color: #ededed;
  min-height: 100vh;
  overflow-x: hidden;
  selection-background-color: #27272a;
  selection-color: #ffffff;
}

/* Czcionka pikselowa dla nagłówków Minecraftowych */
.font-pixel {
  font-family: 'Press Start 2P', cursive, monospace;
}

.font-mono {
  font-family: 'JetBrains Mono', monospace;
}

/* Stylizowany minimalistyczny ciemny scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #000000;
}

::-webkit-scrollbar-thumb {
  background: #181920;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #2a2b36;
}

/* Tło z subtelną ciemną siatką */
.bg-grid-pattern {
  background-color: #030304;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 28px 28px;
}

.bg-radial-glow {
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.03) 0%, rgba(10, 11, 15, 0.8) 50%, #030304 80%);
}

/* Panele i Karty Glassmorphism Stealth */
.glass-panel {
  background: rgba(10, 11, 15, 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--kevvli-border);
}

.glass-panel-hover {
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  background: #090a0e;
}

.glass-panel-hover:hover {
  transform: translateY(-3px);
  background: #0e0f15;
  border-color: var(--kevvli-border-hover);
  box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.95), 0 0 1px 1px rgba(255, 255, 255, 0.08);
}

/* Logo stealth glow */
.logo-glow {
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.8), 0 0 1px 1px rgba(255, 255, 255, 0.15);
  transition: all 0.3s ease;
}

.logo-glow:hover {
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.2), 0 0 2px 1px rgba(255, 255, 255, 0.4);
  transform: scale(1.04);
}

/* Nowoczesne Dark Przyciski */
.mc-btn {
  position: relative;
  transition: all 0.15s ease-in-out;
  cursor: pointer;
  user-select: none;
}

.mc-btn:active {
  transform: translateY(1px);
}

.mc-btn-emerald {
  background: #10b981;
  color: #030304;
  font-weight: 700;
  border: 1px solid #34d399;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}
.mc-btn-emerald:hover {
  background: #34d399;
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.mc-btn-dark {
  background: #111218;
  color: #e4e4e7;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
}
.mc-btn-dark:hover {
  background: #181922;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.22);
}

.mc-btn-white {
  background: #ffffff;
  color: #050508;
  font-weight: 700;
  border: 1px solid #ffffff;
  box-shadow: 0 4px 14px rgba(255, 255, 255, 0.15);
}
.mc-btn-white:hover {
  background: #e4e4e7;
  box-shadow: 0 6px 20px rgba(255, 255, 255, 0.25);
}

/* Badges / Odznaki rozdzielczości w ciemnym stylu */
.badge-res {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.badge-16x { background: #14151c; color: #a1a1aa; border: 1px solid #23242e; }
.badge-32x { background: #0e1726; color: #60a5fa; border: 1px solid #1e2d4a; }
.badge-64x { background: #0c1c15; color: #34d399; border: 1px solid #143828; }
.badge-128x { background: #181124; color: #c084fc; border: 1px solid #301f4a; }
.badge-256x { background: #20170a; color: #fbbf24; border: 1px solid #3d2c12; }
.badge-512x { background: #220e0e; color: #f87171; border: 1px solid #441818; }

/* Dropzone do wgrywania plików w ciemnym stylu */
.dropzone {
  border: 2px dashed #20212b;
  transition: all 0.2s ease;
  background: #08080c;
}

.dropzone.dragover {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.05);
  transform: scale(1.01);
  box-shadow: 0 0 30px rgba(16, 185, 129, 0.15);
}

/* Suwak Przed / Po (Before/After Slider) */
.before-after-container {
  position: relative;
  width: 100%;
  height: 380px;
  overflow: hidden;
  border-radius: 12px;
  user-select: none;
  background: #000000;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.before-image, .after-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.after-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  overflow: hidden;
  border-right: 2px solid #ffffff;
  box-shadow: 2px 0 15px rgba(255, 255, 255, 0.2);
  z-index: 10;
}

.slider-handle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #ffffff;
  color: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.4), 0 4px 12px rgba(0, 0, 0, 0.9);
  cursor: ew-resize;
  z-index: 20;
  transition: transform 0.1s ease;
}

.slider-handle:hover {
  transform: translate(-50%, -50%) scale(1.1);
}

/* Animacje pływania */
@keyframes float {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-5px) rotate(1deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

.animate-float {
  animation: float 4s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 0.9; }
}

.animate-pulse-glow {
  animation: pulse-glow 3s ease-in-out infinite;
}

/* Toast powiadomienia w ciemnym stylu */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: #0d0e14;
  color: white;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 4px solid #10b981;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.95);
  transform: translateX(120%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast.show {
  transform: translateX(0);
}

.toast.toast-error {
  border-left-color: #ef4444;
}

.toast.toast-info {
  border-left-color: #3b82f6;
}

/* Pixel art rendering dla ikon minecraftowych */
.pixelated {
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

/* Kolory formatowania tekstu Minecraft (§a, §c, etc.) */
.mc-color-0 { color: #000000; }
.mc-color-1 { color: #0000AA; }
.mc-color-2 { color: #00AA00; }
.mc-color-3 { color: #00AAAA; }
.mc-color-4 { color: #AA0000; }
.mc-color-5 { color: #AA00AA; }
.mc-color-6 { color: #FFAA00; }
.mc-color-7 { color: #AAAAAA; }
.mc-color-8 { color: #555555; }
.mc-color-9 { color: #5555FF; }
.mc-color-a { color: #55FF55; text-shadow: 0 0 8px rgba(85, 255, 85, 0.4); }
.mc-color-b { color: #55FFFF; text-shadow: 0 0 8px rgba(85, 255, 255, 0.4); }
.mc-color-c { color: #FF5555; }
.mc-color-d { color: #FF55FF; }
.mc-color-e { color: #FFFF55; text-shadow: 0 0 8px rgba(255, 255, 85, 0.4); }
.mc-color-f { color: #FFFFFF; }
.mc-style-l { font-weight: bold; }
.mc-style-m { text-decoration: line-through; }
.mc-style-n { text-decoration: underline; }
.mc-style-o { font-style: italic; }

/* Modal overlay & animacja wejścia w totalnym darku */
.modal-backdrop {
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(16px);
}

.modal-content-anim {
  animation: modalIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalIn {
  0% {
    opacity: 0;
    transform: scale(0.96) translateY(10px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}
