/* ============================================================
   YS FASHIONS — base.css
   Design tokens, reset, typography, layout utilities.
   Palette taken from the brand logo (navy + gold).
   ============================================================ */

:root {
  --color-navy: #0f1c3f;
  --color-navy-dark: #0a1329;
  --color-gold: #b8925a;
  --color-gold-light: #d9b98a;
  --color-cream: #faf8f5;
  --color-white: #ffffff;
  --color-gray-50: #f7f7f8;
  --color-gray-100: #ececee;
  --color-gray-300: #c9c9cf;
  --color-gray-500: #7a7a85;
  --color-gray-700: #45454e;
  --color-gray-900: #1c1c22;
  --color-success: #1e7d4f;
  --color-danger: #b3261e;
  --color-warning: #a86a00;

  --font-heading: Georgia, 'Times New Roman', serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;

  --shadow-sm: 0 1px 2px rgba(15, 28, 63, 0.08);
  --shadow-md: 0 4px 16px rgba(15, 28, 63, 0.10);
  --shadow-lg: 0 12px 32px rgba(15, 28, 63, 0.14);

  --container-max: 1200px;
  --header-height: 64px;
}

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

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

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-gray-900);
  background: var(--color-cream);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 0.5em;
  color: var(--color-navy);
}

h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1em; color: var(--color-gray-700); }

button, input, select, textarea { font-family: inherit; font-size: 1rem; }

ul { list-style: none; margin: 0; padding: 0; }

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 16px;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--color-navy);
  color: var(--color-white);
  padding: 10px 16px;
  z-index: 200;
  border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .05s ease;
  min-height: 44px;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary { background: var(--color-navy); color: var(--color-white); }
.btn-primary:hover:not(:disabled) { background: var(--color-navy-dark); }

.btn-gold { background: var(--color-gold); color: var(--color-navy-dark); }
.btn-gold:hover:not(:disabled) { background: var(--color-gold-light); }

.btn-outline { background: transparent; color: var(--color-navy); border-color: var(--color-navy); }
.btn-outline:hover:not(:disabled) { background: var(--color-navy); color: var(--color-white); }

.btn-block { width: 100%; }
.btn-sm { padding: 8px 14px; min-height: 36px; font-size: 0.85rem; }

/* ---------- Forms ---------- */
.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-navy);
  margin-bottom: 6px;
}
.field input, .field select, .field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-gray-300);
  border-radius: var(--radius-md);
  background: var(--color-white);
  min-height: 44px;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--color-gold);
  outline-offset: 1px;
  border-color: var(--color-gold);
}
.field .error-text {
  color: var(--color-danger);
  font-size: 0.8rem;
  margin-top: 4px;
  display: none;
}
.field.has-error input, .field.has-error select { border-color: var(--color-danger); }
.field.has-error .error-text { display: block; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* ---------- Badges / status ---------- */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.badge-in-stock { background: #e4f4ea; color: var(--color-success); }
.badge-low-stock { background: #fbeecb; color: var(--color-warning); }
.badge-out-stock { background: #f7e2e0; color: var(--color-danger); }

/* ---------- Section spacing ---------- */
.section { padding: 40px 0; }
.section-title { text-align: center; margin-bottom: 28px; }
.section-title p { max-width: 560px; margin: 0 auto; }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.gap-8 { gap: 8px; }
.gap-16 { gap: 16px; }

@media (min-width: 768px) {
  .field-row-desktop-3 { grid-template-columns: 1fr 1fr 1fr; }
}
