/* ---------- tokens ---------- */
:root {
  --cream: #fbf3e7;
  --cream-dark: #f2e4cf;
  --gold: #c9972f;
  --gold-dark: #93691c;
  --gold-light: #e9c477;
  --ink: #3a2e22;
  --ink-soft: #6b5d4c;
  --white: #ffffff;
  --danger: #b3452c;
  --ok: #4a7a4e;
  --radius: 14px;
  --shadow: 0 8px 24px rgba(58, 46, 34, 0.1);
  --font-heading: "Playfair Display", "Noto Serif Armenian", Georgia, serif;
  --font-body: "Noto Sans", "Noto Sans Armenian", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--ink);
  line-height: 1.25;
  margin: 0 0 0.5em;
}

h1 { font-size: 2.4rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1em; }

a { color: var(--gold-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

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

main {
  overflow-x: hidden;
}

.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-heading {
  text-align: center;
  margin-bottom: 1.5rem;
}

.lede {
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 640px;
}

.muted { color: var(--ink-soft); font-size: 0.95rem; }

/* ---------- buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.75em 1.6em;
  border-radius: 999px;
  font-weight: 600;
  border: 2px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  font-family: var(--font-body);
}
.btn-primary {
  background: var(--gold);
  color: var(--white);
}
.btn-primary:hover { background: var(--gold-dark); text-decoration: none; }
.btn-secondary {
  background: transparent;
  border-color: var(--gold);
  color: var(--gold-dark);
}
.btn-secondary:hover { background: var(--gold-light); text-decoration: none; }
.btn-small { padding: 0.5em 1.2em; font-size: 0.9rem; }

.badge {
  display: inline-block;
  background: var(--gold-light);
  color: var(--gold-dark);
  border-radius: 999px;
  padding: 0.3em 1em;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 0.75em;
}

/* ---------- header ---------- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--cream-dark);
  position: sticky;
  top: 0;
  z-index: 20;
}
.site-header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 12px;
  padding-bottom: 12px;
  flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand img { width: 56px; height: auto; }
.brand-name { font-family: var(--font-heading); font-weight: 700; font-size: 1.3rem; color: var(--gold-dark); }
.main-nav { display: flex; gap: 16px; flex-wrap: nowrap; flex: 1; white-space: nowrap; }
.main-nav a { color: var(--ink); font-weight: 500; font-size: 0.92rem; }
.main-nav a:hover { color: var(--gold-dark); }
.header-actions { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  width: 40px;
  height: 40px;
  padding: 0;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex-shrink: 0;
}
.nav-toggle span { display: block; width: 20px; height: 2px; background: var(--ink); border-radius: 2px; }

.lang-switcher { display: flex; gap: 6px; }
.lang-switcher a {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink-soft);
  border: 1px solid var(--cream-dark);
  border-radius: 6px;
  padding: 2px 7px;
}
.lang-switcher a.active { background: var(--gold); color: var(--white); border-color: var(--gold); }
.lang-switcher a:hover { text-decoration: none; border-color: var(--gold); }

/* ---------- hero ---------- */
.hero {
  display: flex;
  gap: 40px;
  align-items: center;
  padding: 56px 24px;
  flex-wrap: wrap;
}
.hero-text { flex: 1 1 380px; min-width: 0; }
.hero-samples {
  flex: 1 1 320px;
  min-width: 0;
  display: flex;
  gap: 12px;
  overflow: hidden;
  padding: 14px;
}
.hero-samples img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  flex: 1;
  min-width: 0;
  object-fit: cover;
  aspect-ratio: 3/4;
  transform: rotate(-3deg);
}
.hero-samples img:nth-child(2) { transform: rotate(2deg) translateY(-10px); }
.hero-samples img:nth-child(3) { transform: rotate(-1deg); }

.page-hero { padding: 48px 24px 24px; text-align: left; }

/* ---------- product cards ---------- */
.products-grid { padding: 24px 24px 48px; }
.cards-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  position: relative;
}
.price-teaser { text-align: center; margin-top: 24px; font-size: 1.05rem; }

.closing-banner {
  text-align: center;
  background: linear-gradient(135deg, var(--gold-light), var(--cream-dark));
  border-radius: var(--radius);
  padding: 48px 24px;
  margin: 24px auto 56px;
}

/* ---------- gallery ---------- */
.gallery { padding: 24px; }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
.gallery-item {
  position: relative;
}
.gallery-item img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: var(--shadow);
}
.gallery-remove-form {
  position: absolute;
  top: 8px;
  right: 8px;
}
.gallery-remove-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: rgba(58, 46, 34, 0.75);
  color: var(--white);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}
.gallery-remove-btn:hover { background: var(--danger); }
.gallery-add-tile {
  aspect-ratio: 3/4;
  border: 2px dashed var(--gold);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10px;
}
.gallery-add-label {
  color: var(--gold-dark);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
}

/* ---------- rich text blocks ---------- */
.rich-text ul { padding-left: 1.4em; }
.rich-text li { margin-bottom: 0.4em; }

.about-story { display: flex; gap: 32px; flex-wrap: wrap; align-items: flex-start; padding: 24px; }
.about-photo { max-width: 320px; border-radius: var(--radius); box-shadow: var(--shadow); }

/* ---------- pricing ---------- */
.pricing-section { padding: 24px; }
.pricing-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 40px;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.pricing-table th, .pricing-table td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--cream-dark);
}
.pricing-table th { background: var(--cream-dark); font-family: var(--font-heading); }
.pricing-table tr:last-child td { border-bottom: none; }

.pricing-strip { padding: 24px; }
.pricing-table-mini { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; margin-bottom: 16px; }
.pricing-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 18px;
  border-bottom: 1px solid var(--cream-dark);
  position: relative;
}
.pricing-row:last-child { border-bottom: none; }

/* ---------- FAQ ---------- */
.faq-section { padding: 24px 24px 56px; }
.faq-list { display: flex; flex-direction: column; gap: 10px; max-width: 760px; margin: 0 auto; }
.faq-item {
  background: var(--white);
  border-radius: 10px;
  padding: 14px 18px;
  box-shadow: var(--shadow);
}
.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.faq-item .rich-text { margin-top: 10px; color: var(--ink-soft); }
.required-info { max-width: 760px; margin: 0 auto; padding: 24px; }

/* ---------- testimonials ---------- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  padding: 24px;
}
.testimonial-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  position: relative;
}
.testimonial-photo { border-radius: 10px; margin-bottom: 12px; aspect-ratio: 4/3; object-fit: cover; }
.testimonial-quote { font-style: italic; }
.testimonial-name { font-weight: 700; color: var(--gold-dark); margin: 0; }
.video-embed { position: relative; padding-top: 56.25%; border-radius: 10px; overflow: hidden; margin-bottom: 12px; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.empty-state { text-align: center; color: var(--ink-soft); grid-column: 1 / -1; }

/* ---------- footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--cream);
  margin-top: 40px;
  padding-top: 40px;
}
.site-footer a { color: var(--cream); }
.site-footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: space-between;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
.footer-brand .brand-name { color: var(--gold-light); font-size: 1.2rem; }
.footer-nav { display: flex; flex-direction: column; gap: 8px; }
.footer-rights { text-align: center; padding: 16px 24px; font-size: 0.85rem; color: rgba(251,243,231,0.6); }

/* ---------- admin bar / flash ---------- */
.admin-bar {
  background: var(--ink);
  color: var(--cream);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 24px;
  font-size: 0.85rem;
  position: sticky;
  top: 0;
  z-index: 30;
}
.admin-bar a, .admin-bar button {
  color: var(--gold-light);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.85rem;
  text-decoration: underline;
}
.admin-bar-actions { display: flex; gap: 16px; }
.inline-form { display: inline; }

.flash-messages { max-width: 1080px; margin: 12px auto 0; padding: 0 24px; }
.flash { padding: 10px 16px; border-radius: 8px; margin-bottom: 8px; font-size: 0.9rem; }
.flash-error { background: #fbe4de; color: var(--danger); }
.flash-ok { background: #e3f0e3; color: var(--ok); }

/* ---------- editable / draft ---------- */
.editable { position: relative; }
.edit-pencil {
  background: var(--white);
  border: 1px solid var(--gold);
  color: var(--gold-dark);
  border-radius: 50%;
  width: 30px;
  height: 30px;
  cursor: pointer;
  font-size: 0.9rem;
  line-height: 1;
  margin-left: 8px;
}
.edit-pencil:hover { background: var(--gold-light); }
.draft-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff3cd;
  color: #7a5c00;
  border: 1px dashed #d8b64c;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 10px;
}
.publish-btn {
  background: var(--gold);
  color: var(--white);
  border: none;
  border-radius: 999px;
  padding: 3px 12px;
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 700;
}
body.is-admin .card, body.is-admin .testimonial-card, body.is-admin .pricing-row {
  outline: 1px dashed rgba(201,151,47,0.4);
  outline-offset: 4px;
}

/* ---------- modal ---------- */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(58,46,34,0.5);
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 560px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  position: relative;
}
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--ink-soft);
}
.modal-box label { display: block; font-weight: 600; font-size: 0.85rem; margin: 14px 0 4px; }
.modal-box input[type="text"],
.modal-box input[type="number"],
.modal-box input[type="url"],
.modal-box input[type="email"],
.modal-box input[type="password"],
.modal-box textarea,
.modal-box select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.modal-preview { max-width: 160px; border-radius: 8px; margin-top: 6px; }
.modal-actions { display: flex; gap: 12px; margin-top: 20px; }
.modal-error { color: var(--danger); font-size: 0.85rem; margin-top: 10px; }
.draft-note { font-size: 0.85rem; color: #7a5c00; background: #fff3cd; padding: 8px 12px; border-radius: 8px; }

/* ---------- admin login / dashboard ---------- */
.admin-login-body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--cream);
}
.admin-login-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 40px;
  width: 100%;
  max-width: 380px;
  text-align: center;
}
.admin-login-logo { width: 120px; margin: 0 auto 16px; }
.admin-login-card form { text-align: left; }
.admin-login-card label { display: block; font-weight: 600; font-size: 0.85rem; margin: 14px 0 4px; }
.admin-login-card input {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  font-size: 0.95rem;
}
.admin-login-card .btn { width: 100%; margin-top: 20px; }
.back-link { display: inline-block; margin-top: 18px; font-size: 0.85rem; }

.admin-dashboard { padding: 32px 24px 64px; }
.admin-section {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  margin-bottom: 28px;
}
.admin-page-list { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.admin-page-list li { background: var(--cream); border-radius: 8px; padding: 6px 14px; }
.admin-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 14px;
  margin-bottom: 12px;
}
.admin-gallery-item {
  background: var(--cream);
  border-radius: 8px;
  padding: 8px;
  text-align: center;
}
.admin-gallery-item img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 6px;
}
.admin-gallery-product { display: block; font-size: 0.75rem; color: var(--ink-soft); margin-bottom: 4px; }
.admin-table { width: 100%; border-collapse: collapse; margin-bottom: 16px; }
.admin-table th, .admin-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--cream-dark); font-size: 0.9rem; }
.admin-row-actions { display: flex; gap: 10px; align-items: center; }
.link-danger { background: none; border: none; color: var(--danger); cursor: pointer; text-decoration: underline; font-size: 0.85rem; padding: 0; }
.status-badge { font-size: 0.75rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.status-badge.status-published { background: #e3f0e3; color: var(--ok); }
.status-badge.status-draft { background: #fff3cd; color: #7a5c00; }
.admin-add-form { margin-top: 12px; }
.admin-add-form summary { cursor: pointer; font-weight: 600; color: var(--gold-dark); }
.stacked-form { display: flex; flex-direction: column; max-width: 480px; margin-top: 12px; }
.stacked-form label { font-weight: 600; font-size: 0.85rem; margin: 10px 0 4px; }
.stacked-form input, .stacked-form textarea, .stacked-form select {
  padding: 8px 10px;
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  font-family: var(--font-body);
}
.stacked-form button { margin-top: 16px; align-self: flex-start; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .nav-toggle { display: flex; }
  .main-nav {
    display: none;
    order: 4;
    flex: 1 1 100%;
    white-space: normal;
    flex-direction: column;
    gap: 2px;
    padding-top: 8px;
    border-top: 1px solid var(--cream-dark);
    margin-top: 10px;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 8px 4px; }
  .site-header-inner { flex-wrap: wrap; }
  .brand { order: 1; }
  .header-actions { order: 2; margin-left: auto; }
  .nav-toggle { order: 3; }
}

@media (max-width: 760px) {
  .cards-2 { grid-template-columns: 1fr; }
  .hero { flex-direction: column; }
  h1 { font-size: 1.9rem; }
}

@media (max-width: 480px) {
  .header-actions .btn { display: none; }
}
