:root {
  --ink: #242321;
  --muted: #6e665d;
  --paper: #f7f4ee;
  --linen: #e9dfd0;
  --sage: #51695d;
  --wine: #743f48;
  --gold: #b28a52;
  --line: rgba(36, 35, 33, 0.12);
  --white: #ffffff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: "Montserrat", Arial, sans-serif;
  background: var(--paper);
  color: var(--ink);
}

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

button,
input,
select {
  font: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px clamp(18px, 5vw, 56px);
  background: rgba(247, 244, 238, 0.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.brand {
  color: var(--ink);
  font-size: clamp(18px, 2vw, 25px);
  font-weight: 400;
  letter-spacing: 7px;
  text-decoration: none;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 18px;
}

.nav-links a {
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
}

.admin-link {
  color: var(--wine) !important;
}

.hero {
  max-width: 1280px;
  min-height: 620px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 440px);
  align-items: center;
  gap: clamp(28px, 6vw, 76px);
  padding: clamp(52px, 8vw, 104px) clamp(18px, 5vw, 56px);
}

.hero-media {
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 30px 80px rgba(36, 35, 33, 0.16);
}

.hero-media::after {
  display: none;
}

.hero-media img {
  width: 100%;
  height: min(62vh, 560px);
  min-height: 430px;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.hero-media:hover img {
  transform: scale(1.04);
}

.hero-copy {
  position: relative;
  max-width: 760px;
  color: var(--ink);
}

.eyebrow {
  color: var(--gold);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 4px;
  line-height: 1.6;
  text-transform: uppercase;
}

.hero-copy h1,
.admin-intro h1 {
  margin-top: 16px;
  font-size: clamp(54px, 9vw, 132px);
  font-weight: 300;
  line-height: 0.95;
}

.hero-copy p:last-child,
.admin-intro p:last-child {
  max-width: 600px;
  margin-top: 22px;
  color: var(--muted);
  font-size: clamp(16px, 2vw, 22px);
  line-height: 1.6;
}

.section,
.contact,
.admin-shell {
  padding: clamp(52px, 8vw, 110px) clamp(18px, 5vw, 56px);
}

.alt {
  background: #eef0e7;
}

.section-title {
  max-width: 1280px;
  margin: 0 auto;
}

.section-title h2,
.contact-copy h2,
.admin-preview h2 {
  margin-top: 12px;
  font-size: clamp(34px, 5vw, 64px);
  font-weight: 300;
}

.products {
  max-width: 1280px;
  margin: 42px auto 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.product-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 20px 50px rgba(36, 35, 33, 0.08);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 60px rgba(36, 35, 33, 0.12);
}

.product-card img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.product-body {
  padding: 20px;
}

.product-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.product-heading h3 {
  font-size: 20px;
  font-weight: 500;
  line-height: 1.3;
}

.price,
.modal-price {
  color: var(--wine);
  font-weight: 700;
  white-space: nowrap;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 11px;
  background: #faf8f4;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.empty {
  grid-column: 1 / -1;
  padding: 34px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.contact {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 42px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.contact-grid article,
.admin-form,
.admin-preview {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 28px;
  box-shadow: 0 18px 45px rgba(36, 35, 33, 0.08);
}

.contact-grid h3 {
  margin-bottom: 12px;
  color: var(--sage);
  font-size: 19px;
}

.contact-grid p {
  color: var(--muted);
  line-height: 1.9;
}

footer {
  padding: 30px;
  color: var(--muted);
  text-align: center;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(20, 20, 18, 0.65);
  backdrop-filter: blur(8px);
}

.modal.is-open {
  display: flex;
}

.modal-panel {
  position: relative;
  width: min(980px, 100%);
  max-height: 90vh;
  overflow: auto;
  border-radius: 8px;
  background: var(--paper);
  padding: clamp(20px, 4vw, 42px);
}

.close-button {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  cursor: pointer;
  font-size: 26px;
}

.modal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 34px;
  align-items: center;
}

.modal-grid img {
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: 8px;
  object-fit: cover;
}

.modal-gallery {
  display: grid;
  gap: 12px;
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(58px, 1fr));
  gap: 10px;
}

.gallery-thumb {
  border: 2px solid transparent;
  border-radius: 8px;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.gallery-thumb.is-active {
  border-color: var(--wine);
}

.gallery-thumb img {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 6px;
  object-fit: cover;
}

.modal-grid h2 {
  margin-top: 12px;
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 300;
}

.modal-price {
  margin-top: 14px;
  font-size: 24px;
}

.admin-page {
  background: #eef0e7;
}

.admin-intro {
  max-width: 980px;
}

.admin-intro h1 {
  color: var(--ink);
}

.admin-intro p:last-child {
  color: var(--muted);
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(320px, 460px) 1fr;
  gap: 24px;
  margin-top: 38px;
}

.admin-form {
  display: grid;
  gap: 18px;
  align-self: start;
}

.admin-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.field-help {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
}

.admin-form input,
.admin-form select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfaf7;
  padding: 13px 14px;
  color: var(--ink);
}

.admin-form button {
  border: 0;
  border-radius: 8px;
  background: var(--sage);
  color: var(--white);
  padding: 15px 18px;
  cursor: pointer;
  font-weight: 700;
}

.form-message {
  min-height: 22px;
  color: var(--wine);
  font-size: 14px;
  line-height: 1.5;
}

.form-message.success {
  color: var(--sage);
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.login-card {
  width: min(440px, 100%);
  display: grid;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: clamp(24px, 5vw, 42px);
  box-shadow: 0 24px 70px rgba(36, 35, 33, 0.12);
}

.login-card h1 {
  font-size: clamp(34px, 6vw, 54px);
  font-weight: 300;
}

.login-card label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.login-card input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfaf7;
  padding: 13px 14px;
  color: var(--ink);
}

.login-card button {
  border: 0;
  border-radius: 8px;
  background: var(--sage);
  color: var(--white);
  padding: 15px 18px;
  cursor: pointer;
  font-weight: 700;
}

.admin-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.admin-mini {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
}

.admin-mini img {
  width: 86px;
  height: 100px;
  border-radius: 6px;
  object-fit: cover;
}

.admin-mini h3 {
  font-size: 15px;
  line-height: 1.35;
}

.admin-mini p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 980px) {
  .hero,
  .products,
  .contact,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .hero-media img {
    height: auto;
    min-height: 0;
    aspect-ratio: 4 / 5;
  }

  .contact-grid,
  .admin-products {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 680px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-links {
    justify-content: flex-start;
  }

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

  .brand {
    letter-spacing: 4px;
  }
}
