/*
 * Core design variables and base layout
 */
:root {
  --primary: #ec1337;
  --bg: #fcf8f9;
  --ink: #1b0d10;
  --muted: #9a4c59;
}

* {
  box-sizing: border-box;
}

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

body {
  font-family: "Epilogue", system-ui, -apple-system, Segoe UI, Roboto, Helvetica,
    Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
}

/* Utility classes */
.container {
  width: min(1100px, 90%);
  margin-inline: auto;
}

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

.right {
  text-align: right;
}

.spacer {
  height: 1rem;
}

h1 {
  font-size: clamp(2rem, 5vw, 2.8rem);
  margin: 0 0 0.75rem;
  font-weight: 900;
}

h2 {
  font-size: clamp(1.6rem, 3.5vw, 2rem);
  margin: 0.5rem 0;
}

h3 {
  font-size: 1.25rem;
  margin: 0.35rem 0;
}

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

.link {
  color: var(--primary);
  text-decoration: none;
}
.link:hover {
  text-decoration: underline;
}

/* Header & navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(252, 248, 249, 0.9);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}

.brand {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  text-decoration: none;
  color: var(--ink);
  font-weight: 800;
}

.main-nav {
  display: none;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.main-nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  opacity: 0.9;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--primary);
}

@media (min-width: 820px) {
  .main-nav {
    display: flex;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 0.8rem 1.2rem;
  text-decoration: none;
  font-weight: 800;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  filter: brightness(0.9);
}

.btn-outline {
  border: 2px solid var(--primary);
  color: var(--primary);
  background: transparent;
}

.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}

.btn-lg {
  padding: 1rem 1.6rem;
  font-size: 1.125rem;
}

.btn-sm {
  border: 1px solid #ead6db;
  border-radius: 10px;
  padding: 0.5rem 0.8rem;
  background: #f9e2e7;
  font-weight: 700;
}

.btn.full {
  width: 100%;
}

/* Hero section */
.hero {
  position: relative;
  min-height: 70vh;
  display: grid;
  place-items: center;
  color: #fff;
  background-size: cover;
  background-position: center;
}

.hero .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.2));
}

.hero-inner {
  position: relative;
  text-align: center;
  padding: 6rem 0;
}

.hero-inner h1 {
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 1.1;
  margin: 0 0 1rem;
  font-weight: 900;
}

.hero-inner p {
  max-width: 46ch;
  margin: 0 auto 1.5rem;
  font-size: 1.125rem;
  color: #f5e7ea;
}

/* Sections */
.section {
  padding: 4rem 0;
  background: #fff;
}

.section.alt {
  background: var(--bg);
}

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

/* Grid & cards */
.product-grid,
.cards,
.option-group {
  display: grid;
  gap: 1.5rem;
}

.product-grid {
  grid-template-columns: 1fr;
}

@media (min-width: 600px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.cards.three {
  grid-template-columns: 1fr;
}

@media (min-width: 820px) {
  .cards.three {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s, box-shadow 0.25s;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.12);
}

.card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.product-card img,
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
}

.price {
  color: var(--primary);
  font-weight: 800;
}

/* Footer */
.site-footer {
  background: #1b0d10;
  color: #fff;
  padding: 2rem 0;
}

.site-footer .social {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 0.5rem;
}

.site-footer a {
  color: #fff;
  text-decoration: none;
  opacity: 0.9;
}

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

/* Forms and Profile */
.profile-form {
  display: grid;
  gap: 2rem;
}

.profile-form section {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
  padding: 1.25rem;
}

.profile-form h2 {
  margin-top: 0;
}

.form-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

.form-grid.two {
  grid-template-columns: 1fr 1fr;
}

@media (max-width: 600px) {
  .form-grid.two {
    grid-template-columns: 1fr;
  }
}

.address-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 600px) {
  .address-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-weight: 600;
  color: var(--ink);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="password"],
select,
textarea {
  width: 100%;
  border: 1px solid #ead6db;
  border-radius: 10px;
  padding: 0.75rem;
  font: inherit;
  background: #fcf8f9;
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid var(--primary);
}

.option-card,
.payment-card {
  border: 1px solid var(--muted);
  border-radius: 14px;
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.option-card:hover,
.payment-card:hover {
  border-color: var(--primary);
}

.option-card.selected,
.payment-card.selected {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(236, 19, 55, 0.3);
}

.option-card input {
  margin-right: 0.75rem;
  accent-color: var(--primary);
}

.payment-card img {
  height: 28px;
  width: auto;
}

/* Stepper */
.stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  position: relative;
}

.stepper .step {
  position: relative;
  flex: 1;
  text-align: center;
  font-weight: 700;
  color: var(--muted);
}

.stepper .step .circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #ead6db;
  color: #fff;
  font-weight: 700;
  margin: 0 auto 0.4rem;
}

.stepper .step.completed .circle,
.stepper .step.current .circle {
  background: var(--primary);
}

.stepper .step.current {
  color: var(--ink);
}

.stepper .step.completed {
  color: var(--primary);
}

.stepper .step:after {
  content: '';
  position: absolute;
  top: 17px;
  left: 50%;
  width: 100%;
  height: 2px;
  background: #ead6db;
  z-index: -1;
}

.stepper .step:first-child:after {
  width: 50%;
  left: 50%;
}

.stepper .step:last-child:after {
  width: 50%;
}

/* Checkout layout */
.checkout-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
}

@media (min-width: 960px) {
  .checkout-grid {
    grid-template-columns: 2fr 1fr;
  }
}

.order-summary {
  background: #fff;
  border: 1px solid #f3e7e9;
  border-radius: 16px;
  padding: 1.25rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
  position: sticky;
  top: 90px;
  align-self: start;
}

.order-summary h3 {
  margin-top: 0;
  margin-bottom: 1rem;
}

.summary-items {
  display: grid;
  gap: 0.8rem;
  margin-bottom: 1.2rem;
}

.summary-items .item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95rem;
}

.summary-items .item .name {
  flex: 1;
}

.summary-items .item .qty {
  margin: 0 0.5rem;
}

.summary-items .item .price {
  color: var(--primary);
  font-weight: 700;
}

.summary-totals {
  border-top: 1px solid #f3e7e9;
  padding-top: 1rem;
  display: grid;
  gap: 0.5rem;
}

.summary-totals div {
  display: flex;
  justify-content: space-between;
}

/* Tables */
.table-wrap {
  overflow: auto;
  border: 1px solid #f3e7e9;
  border-radius: 14px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

.table th,
.table td {
  padding: 1rem;
  border-bottom: 1px solid #f3e7e9;
  text-align: left;
}

.table thead th {
  background: #f9e2e7;
}

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

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #eee;
  color: #555;
  padding: 0.25rem 0.6rem;
  font-weight: 700;
  font-size: 0.8rem;
}

.badge.success {
  background: #dcfce7;
  color: #166534;
}

.badge.info {
  background: #dbeafe;
  color: #1e3a8a;
}