/* =========================================================
   Variables
   ========================================================= */
:root {
  /* Color Palette - inspired by soft whites, graphite grays, sky blues, warm beiges, natural wood */
  --color-background: #f6f7f8; /* soft, calm neutral for page background */
  --color-surface: #ffffff; /* primary surface / card background */
  --color-surface-muted: #f0f2f4; /* subtle contrast for panels/sections */

  --color-text: #1f2429; /* primary body text (graphite-inspired) */
  --color-text-muted: #6f747a; /* secondary text, labels, meta */
  --color-border-subtle: #dde1e6;
  --color-border-strong: #b7bec6;

  --color-primary: #2f6fae; /* calm sky blue for actions */
  --color-primary-soft: #e3effa;
  --color-primary-strong: #215485;

  --color-success: #268d62; /* quality, reliability */
  --color-success-soft: #e0f4eb;

  --color-warning: #c78a2a; /* warm beige-gold accent */
  --color-warning-soft: #f8edd9;

  --color-danger: #b63a3a; /* error / destructive */
  --color-danger-soft: #f9e1e1;

  --color-gray-50: #f8f9fa;
  --color-gray-100: #f1f3f5;
  --color-gray-200: #e5e8ec;
  --color-gray-300: #d0d5dc;
  --color-gray-400: #b7bec6;
  --color-gray-500: #8a939f;
  --color-gray-600: #6f747a;
  --color-gray-700: #4c5258;
  --color-gray-800: #2f3439;
  --color-gray-900: #191d21;

  --color-accent-wood: #b88a5b; /* natural wood tone accent */

  /* Typography */
  --font-sans: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-heading: "Space Grotesk", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  --font-size-xs: 0.75rem;   /* 12px */
  --font-size-sm: 0.875rem;  /* 14px */
  --font-size-md: 1rem;      /* 16px */
  --font-size-lg: 1.125rem;  /* 18px */
  --font-size-xl: 1.25rem;   /* 20px */
  --font-size-2xl: 1.5rem;   /* 24px */
  --font-size-3xl: 1.875rem; /* 30px */
  --font-size-4xl: 2.25rem;  /* 36px */

  --line-height-tight: 1.2;
  --line-height-snug: 1.35;
  --line-height-normal: 1.5;
  --line-height-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 */

  /* Radii */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 18px;
  --radius-full: 999px;

  /* Shadows - architectural, subtle, layered */
  --shadow-soft: 0 8px 18px rgba(15, 23, 42, 0.05);
  --shadow-medium: 0 18px 40px rgba(15, 23, 42, 0.08);
  --shadow-strong: 0 24px 60px rgba(15, 23, 42, 0.15);

  /* Transitions */
  --transition-fast: 150ms ease-out;
  --transition-normal: 220ms ease-out;
  --transition-slow: 320ms ease-out;
}

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

/* =========================================================
   Reset / Normalize
   ========================================================= */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
}

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

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

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

img {
  height: auto;
}

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

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

textarea {
  resize: vertical;
}

/* Remove default link styling */
a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

/* Make sure hidden attribute actually hides elements */
[hidden] {
  display: none !important;
}

/* =========================================================
   Base Typography & Layout
   ========================================================= */
body {
  font-family: var(--font-sans);
  font-size: var(--font-size-md);
  line-height: var(--line-height-normal);
  background-color: var(--color-background);
  color: var(--color-text);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

main {
  min-height: 100vh;
}

/* Headings - architectural, structured, with controlled rhythm */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--color-gray-900);
}

h1 {
  font-size: clamp(2.4rem, 3vw, 3rem);
  line-height: var(--line-height-tight);
  margin-bottom: var(--space-4);
}

h2 {
  font-size: clamp(2rem, 2.5vw, 2.4rem);
  line-height: var(--line-height-tight);
  margin-bottom: var(--space-3);
}

h3 {
  font-size: clamp(1.5rem, 2vw, 1.875rem);
  line-height: var(--line-height-snug);
  margin-bottom: var(--space-2);
}

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

h5 {
  font-size: var(--font-size-lg);
  line-height: var(--line-height-snug);
  margin-bottom: var(--space-1);
}

h6 {
  font-size: var(--font-size-md);
  line-height: var(--line-height-snug);
  margin-bottom: var(--space-1);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
}

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

small {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

strong {
  font-weight: 600;
}

/* Links - subtle, trustworthy */
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-primary-strong);
}

a:active {
  color: var(--color-primary-strong);
}

/* Lists */
ul, ol {
  padding-left: 1.25rem;
  margin-bottom: var(--space-3);
}

/* Horizontal rules */
hr {
  border: none;
  border-top: 1px solid var(--color-border-subtle);
  margin: var(--space-6) 0;
}

/* =========================================================
   Accessibility & Focus Styles
   ========================================================= */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

:focus {
  outline: none;
}

/* 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;
}

/* Respect prefers-reduced-motion beyond transitions */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* =========================================================
   Layout Utilities
   ========================================================= */

/* Container - centered content with breathable padding */
.container {
  width: 100%;
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

@media (min-width: 1200px) {
  .container {
    max-width: 1200px;
  }
}

/* Full-bleed section helper for architectural imagery */
.section-full {
  width: 100%;
  padding: var(--space-12) 0;
}

.section-muted {
  background-color: var(--color-surface-muted);
}

/* Flex utilities */
.flex {
  display: flex;
}

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

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

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

.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;
}

.justify-end {
  justify-content: flex-end;
}

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

.gap-sm {
  gap: var(--space-3);
}

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

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

/* Grid utilities */
.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);
}

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

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

/* Width helpers */
.w-full {
  width: 100%;
}



/* Spacing utilities (margin & padding) */
.mt-0 { margin-top: 0; }
.mt-xs { margin-top: var(--space-2); }
.mt-sm { margin-top: var(--space-3); }
.mt-md { margin-top: var(--space-4); }
.mt-lg { margin-top: var(--space-6); }
.mt-xl { margin-top: var(--space-8); }

.mb-0 { margin-bottom: 0; }
.mb-xs { margin-bottom: var(--space-2); }
.mb-sm { margin-bottom: var(--space-3); }
.mb-md { margin-bottom: var(--space-4); }
.mb-lg { margin-bottom: var(--space-6); }
.mb-xl { margin-bottom: var(--space-8); }

.pt-0 { padding-top: 0; }
.pt-sm { padding-top: var(--space-3); }
.pt-md { padding-top: var(--space-4); }
.pt-lg { padding-top: var(--space-6); }
.pt-xl { padding-top: var(--space-8); }

.pb-0 { padding-bottom: 0; }
.pb-sm { padding-bottom: var(--space-3); }
.pb-md { padding-bottom: var(--space-4); }
.pb-lg { padding-bottom: var(--space-6); }
.pb-xl { padding-bottom: var(--space-8); }

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

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

/* =========================================================
   Form Elements & Inputs
   ========================================================= */

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="search"],
input[type="password"],
select,
textarea {
  width: 100%;
  padding: 0.75rem 0.875rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border-subtle);
  background-color: var(--color-surface);
  color: var(--color-text);
  font-size: var(--font-size-md);
  line-height: var(--line-height-normal);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}

input::placeholder,
textarea::placeholder {
  color: var(--color-text-muted);
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px var(--color-primary-soft);
}

input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
  background-color: var(--color-gray-100);
  color: var(--color-text-muted);
}

label {
  display: inline-block;
  margin-bottom: 0.35rem;
  font-size: var(--font-size-sm);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.field-help {
  margin-top: 0.25rem;
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
}

.field-error {
  margin-top: 0.25rem;
  font-size: var(--font-size-xs);
  color: var(--color-danger);
}

/* =========================================================
   Buttons
   ========================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  font-size: var(--font-size-sm);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition:
    background-color var(--transition-normal),
    color var(--transition-normal),
    border-color var(--transition-normal),
    box-shadow var(--transition-normal),
    transform var(--transition-fast);
}

.btn-primary {
  background-color: var(--color-primary);
  color: #ffffff!important;
  border-color: var(--color-primary);
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
  background-color: var(--color-primary-strong);
  border-color: var(--color-primary-strong);
  box-shadow: var(--shadow-medium);
  transform: translateY(-1px);
}

.btn-primary:active {
  background-color: var(--color-primary-strong);
  box-shadow: none;
  transform: translateY(0);
}

.btn-secondary {
  background-color: transparent;
  color: var(--color-gray-900);
  border-color: var(--color-border-strong);
}

.btn-secondary:hover {
  border-color: var(--color-gray-700);
  background-color: var(--color-gray-50);
}

.btn-ghost {
  background-color: transparent;
  color: var(--color-primary);
  border-color: transparent;
}

.btn-ghost:hover {
  background-color: var(--color-primary-soft);
}

.btn-wood {
  background-color: var(--color-accent-wood);
  border-color: var(--color-accent-wood);
  color: #fff;
}

.btn-wood:hover {
  background-color: #a37446;
  border-color: #a37446;
}

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

.btn-icon {
  padding-inline: 0.9rem;
}

/* =========================================================
   Cards & Surfaces
   ========================================================= */

.card {
  position: relative;
  background-color: var(--color-surface);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(209, 213, 219, 0.6);
  box-shadow: var(--shadow-soft);
  padding: var(--space-5);
}

.card-muted {
  background-color: var(--color-surface-muted);
}

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

.card-title {
  font-family: var(--font-heading);
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-1);
}

.card-meta {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

.card-section + .card-section {
  margin-top: var(--space-4);
}

/* Product imagery framing - architectural feel */
.frame-soft {
  border-radius: var(--radius-md);
  overflow: hidden;
  background-color: var(--color-gray-100);
}

.frame-soft img {
  width: 100%;
  height: auto;
  display: block;
}

/* =========================================================
   Badges, Tags & Meta Elements
   ========================================================= */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 1px solid transparent;
}

.badge-soft {
  background-color: var(--color-primary-soft);
  color: var(--color-primary-strong);
}

.badge-neutral {
  background-color: var(--color-gray-100);
  color: var(--color-gray-700);
}

.badge-success {
  background-color: var(--color-success-soft);
  color: var(--color-success);
}

/* =========================================================
   Helper Classes for Polish Locale
   ========================================================= */

/* Subtle helpers for language-specific typography when needed */
.lang-pl {
  hyphens: auto;
}

/* =========================================================
   Media & Imagery
   ========================================================= */

.img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.img-contain {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Architectural split layout for hero sections */
.split-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.2fr);
  gap: var(--space-8);
  align-items: stretch;
}

@media (max-width: 960px) {
  .split-hero {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* =========================================================
   Misc Utilities
   ========================================================= */

.shadow-soft {
  box-shadow: var(--shadow-soft);
}

.shadow-medium {
  box-shadow: var(--shadow-medium);
}

.shadow-none {
  box-shadow: none;
}

.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-full { border-radius: var(--radius-full); }

.bg-surface { background-color: var(--color-surface); }
.bg-muted { background-color: var(--color-surface-muted); }
.bg-primary-soft { background-color: var(--color-primary-soft); }

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

.border-subtle { border: 1px solid var(--color-border-subtle); }
.border-strong { border: 1px solid var(--color-border-strong); }

.opacity-muted { opacity: 0.7; }

.cursor-pointer { cursor: pointer; }

/* End of base.css */
