/* Section: Base / Theme */
:root {
  --bg: #f5e6d1;
  --bg-2: #e9d5b9;
  --surface: rgba(255, 255, 255, 0.20);
  --surface-2: rgba(255, 255, 255, 0.12);
  --text: #0a0a0a;
  --muted: #5a5250;
  --accent: #8a1e2a;
  --accent-2: #b24a62;
  --shadow: 0 8px 28px rgba(0,0,0,.15);
  --radius: 14px;
  --focus: 3px solid color-m-mix(in srgb, var(--accent) 60%, white);
  --gap: 1rem;
  --pad: 1rem;
  --speed: 0.2s;
}

*,
*::before,
*::after { box-sizing: border-box; }
html, body { height: 100%; }
html { -webkit-font-smoothing: antialiased; }

html, body, header, nav, main, article, footer, aside {
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial;
  color: var(--text);
}

/* Section: Layout & Background (mobile-first) */
html, body {
  margin: 0;
  padding: 0;
  background:
    linear-gradient(to bottom, #f5e9cf 0%, #e0d3b8 60%, #d2c1ac 100%),
    radial-gradient(circle at 10% -10%, rgba(255,255,255,.85) 0 25%, transparent 40%),
    repeating-linear-gradient(to bottom, rgba(0,0,0,.04) 0 2px, transparent 2px 4px);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.5;
  font-size: clamp(14px, 1.2vw + 12px, 18px);
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}

/* Section: Global primitives */
ul, li { margin: 0; padding: 0; list-style: none; }
a, button, .btn, .cta { text-decoration: none; color: inherit; }

/* Section: Header / Hero */
header {
  padding: 1rem;
  display: grid;
  gap: 0.5rem;
  place-items: center;
}
header h1 {
  font-size: clamp(1.6rem, 2.2vw + 1rem, 2.9rem);
  line-height: 1.08;
  margin: 0.25rem 0 0.6rem;
  letter-spacing: .2px;
  text-align: center;
  color: var(--text);
}
nav {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}
nav a {
  padding: .5rem .75rem;
  border-radius: 999px;
  border: 1px solid rgba(139,0,25,.4);
  background: rgba(255,255,255,.28);
  color: var(--accent);
  font-weight: 600;
}
nav a:hover { text-decoration: underline; }

/* Section: Main content (image frame) */
main {
  display: grid;
  place-items: center;
  padding: 1rem;
}
.article {
  width: min(100%, 1100px);
}
.image-frame {
  width: min(92%, 800px);
  margin: 0 auto;
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.28);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.image-frame img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
@supports not ((backdrop-filter: blur(12px)) or (-webkit-backdrop-filter: blur(12px))) {
  .image-frame {
    background: rgba(255,255,255,.22);
  }
}

/* Section: Content utility */
.content {
  padding: 0.75rem 1rem;
  color: var(--text);
}
.card {
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 12px;
  padding: .75rem;
  box-shadow: var(--shadow);
}
.grid {
  display: grid;
  gap: var(--gap);
}
.container {
  width: 100%;
  max-width: clamp(320px, 90vw, 1200px);
  margin-inline: auto;
  padding-inline: 0;
}
.tag {
  display: inline-block;
  padding: .15rem .5rem;
  border-radius: 999px;
  font-size: .75rem;
  background: rgba(138, 30, 42, .28);
  color: #fff;
  border: 1px solid rgba(138, 30, 42, .6);
}

/* Section: Product / Ad blocks in footer */
.product-ad {
  display: block;
  margin: 0.75rem 0;
  padding: .6rem;
  border-radius: 12px;
  background: rgba(255,255,255,.24);
  border: 1px solid rgba(0,0,0,.08);
  text-align: center;
}
.product-ad a {
  color: var(--accent);
  display: inline-block;
  padding: .5rem 1rem;
  border-radius: 8px;
  border: 1px solid rgba(139,0,25,.4);
  background: rgba(255,255,255,.28);
  font-weight: 600;
}
.product-ad a:hover { text-decoration: none; transform: translateY(-1px); }

/* Section: Buttons & links */
.btn, .cta, a, button {
  transition: transform var(--speed) ease, background var(--speed) ease;
}
.btn {
  display: inline-block;
  padding: .6rem 1rem;
  border-radius: 8px;
  border: 1px solid rgba(139,0,25,.5);
  background: linear-gradient(#9a1e36, #7a0a2a);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}
.btn:hover { transform: translateY(-1px); background: linear-gradient(#a01f37, #7b0f2a); }
.btn:active { transform: translateY(0); opacity: .95; }
.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(139,0,25,.6);
}
.btn-outline:hover { background: rgba(139,0,25,.08); }

/* Focus visibility (WCAG AA) */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.cta:focus-visible {
  outline: 3px solid rgba(122, 0, 38, 0.95);
  outline-offset: 4px;
  border-radius: 6px;
}
a:focus-visible { text-decoration: underline; }

/* Section: Typography helpers (responsive) */
h1, h2, h3 { line-height: 1.15; font-weight: 700; }
p { margin: 0.5rem 0 0.9rem; color: var(--muted); }

/* Section: Form styles (present as baseline) */
input, select, textarea {
  font: inherit;
  padding: .5rem .75rem;
  border-radius: 6px;
  border: 1px solid rgba(0,0,0,.2);
  background: rgba(255,255,255,.9);
  color: var(--text);
}
input::placeholder { color: #6b6b6b; }

/* Section: Print (basic readability) */
@media print {
  body { background: #fff; color: #000; }
  a { text-decoration: underline; }
  header, nav, footer { display: none; }
}
