/* ============================================================================
   Sip'n Tee Shop — mint boutique theme
   Palette: signature mint #A3E2C9 on clean white.
   ========================================================================== */

:root {
  --mint: #a3e2c9;
  --mint-deep: #6fcfa6;
  --mint-tint: #eef9f3;
  --lavender: #b39ddb;       /* logo wordmark accent */
  --lavender-deep: #8b7bd8;
  --ink: #1f2a24;
  --ink-soft: #586b61;
  --white: #ffffff;
  --line: #e7efe9;
  --shadow: 0 12px 30px rgba(31, 42, 36, 0.08);
  --shadow-lg: 0 24px 60px rgba(31, 42, 36, 0.16);
  --radius: 18px;
  --radius-sm: 12px;
  --maxw: 1160px;
  --font: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --serif: 'Georgia', 'Times New Roman', serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--white);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

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

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

.muted { color: var(--ink-soft); }
.center { text-align: center; }
.hidden { display: none !important; }

h1, h2, h3 { line-height: 1.2; margin: 0 0 0.4em; }
h1 { font-size: clamp(2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); }

/* ---- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: none; cursor: pointer; font-family: inherit; font-weight: 600;
  font-size: 0.98rem; padding: 13px 24px; border-radius: 999px;
  transition: transform 0.12s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--mint); color: var(--ink); }
.btn-primary:hover { background: var(--mint-deep); box-shadow: var(--shadow); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--mint-deep); color: var(--mint-deep); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #2f4239; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-block { width: 100%; }

/* ---- Header / Nav -------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; color: var(--lavender-deep); }
.brand .dot { width: 26px; height: 26px; border-radius: 50%; background: var(--mint); display: inline-block; }
.brand .brand-logo { height: 40px; width: 40px; border-radius: 10px; object-fit: cover; }
/* Logo lockup used on the hero + about header */
.hero-logo { width: 100%; height: 100%; object-fit: cover; }
.pdp-maker { color: var(--lavender-deep); font-weight: 700; font-size: 0.92rem; margin: 4px 0 0; }
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { font-weight: 500; color: var(--ink-soft); }
.nav-links a:hover { color: var(--ink); }
.cart-btn { position: relative; background: var(--mint-tint); border: none; cursor: pointer; padding: 10px 16px; border-radius: 999px; font-weight: 600; }
.cart-count {
  position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px;
  background: var(--ink); color: #fff; border-radius: 999px; font-size: 0.7rem;
  display: flex; align-items: center; justify-content: center; padding: 0 5px;
}

/* ---- Hero ---------------------------------------------------------------- */
.hero {
  background: radial-gradient(120% 120% at 80% 0%, var(--mint-tint) 0%, #fff 60%);
  padding: 70px 0 80px;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 50px; align-items: center; }
.hero-kicker {
  display: inline-block; background: var(--mint); color: var(--ink);
  font-weight: 700; font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 6px 14px; border-radius: 999px; margin-bottom: 18px;
}
.hero p.lead { font-size: 1.15rem; color: var(--ink-soft); max-width: 30ch; margin: 0 0 26px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-art {
  aspect-ratio: 4 / 4.4; border-radius: 28px; background: var(--mint);
  background-image: linear-gradient(140deg, var(--mint) 0%, var(--mint-deep) 100%);
  box-shadow: var(--shadow-lg); position: relative; overflow: hidden;
}
.hero-art .badge {
  position: absolute; bottom: 18px; left: 18px; background: #fff; padding: 10px 16px;
  border-radius: 14px; font-weight: 700; box-shadow: var(--shadow);
}

/* ---- Sections ------------------------------------------------------------ */
.section { padding: 72px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; margin-bottom: 34px; flex-wrap: wrap; gap: 12px; }
.section-head p { margin: 0; color: var(--ink-soft); }
.eyebrow { color: var(--mint-deep); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.78rem; }

/* ---- Product grid -------------------------------------------------------- */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 26px; }
.product-card {
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: #fff; transition: transform 0.18s ease, box-shadow 0.22s ease;
  display: flex; flex-direction: column;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.product-media { position: relative; aspect-ratio: 1 / 1; background: var(--mint-tint); overflow: hidden; }
.product-media img, .product-media video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: opacity 0.3s ease;
}
.product-media video { opacity: 0; }
.product-card:hover .product-media video { opacity: 1; }
.product-media .ph {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: var(--mint-deep); font-weight: 700; font-size: 0.9rem;
}
.product-body { padding: 18px 18px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.product-body .cat { font-size: 0.74rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--mint-deep); font-weight: 700; }
.product-body h3 { font-size: 1.12rem; margin: 0; }
.product-body .tag { color: var(--ink-soft); font-size: 0.92rem; flex: 1; }
.product-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; }
.price { font-weight: 800; font-size: 1.1rem; }

/* ---- Reviews ------------------------------------------------------------- */
.reviews { background: var(--mint-tint); }
.review-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 22px; }
.review-card {
  background: #fff; border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 12px;
}
.review-stars { color: #f5b301; letter-spacing: 2px; font-size: 1.05rem; }
.review-card p { margin: 0; font-size: 1.02rem; }
.review-meta { display: flex; align-items: center; gap: 10px; margin-top: auto; }
.review-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--mint); display: flex; align-items: center; justify-content: center; font-weight: 800; color: var(--ink); }
.review-meta .who { font-weight: 700; }
.review-meta .handle { color: var(--ink-soft); font-size: 0.85rem; }

/* ---- About / Makers ------------------------------------------------------ */
.makers { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }
.maker-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.maker-photo { aspect-ratio: 4 / 3; background: var(--mint); background-image: linear-gradient(140deg, var(--mint), var(--mint-deep)); }
.maker-photo img { width: 100%; height: 100%; object-fit: cover; }
.maker-body { padding: 22px; }
.maker-body .role { color: var(--mint-deep); font-weight: 700; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.06em; }
.maker-body h3 { margin: 4px 0 10px; }
.maker-body .tiktok { display: inline-flex; gap: 6px; align-items: center; margin-top: 14px; font-weight: 600; color: var(--ink); }

/* ---- Product detail page ------------------------------------------------- */
.pdp { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; padding-top: 40px; }
.pdp-gallery { position: sticky; top: 90px; align-self: start; }
.pdp-hero {
  border-radius: var(--radius); overflow: hidden; aspect-ratio: 1 / 1;
  background: var(--mint-tint); position: relative;
}
.pdp-hero img, .pdp-hero video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pdp-hero video { opacity: 0; transition: opacity 0.3s ease; }
.pdp-hero:hover video { opacity: 1; }
.pdp-thumbs { display: flex; gap: 10px; margin-top: 12px; }
.pdp-thumbs img { width: 72px; height: 72px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); cursor: pointer; }

.pdp-info .cat { color: var(--mint-deep); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.8rem; }
.pdp-info h1 { margin: 6px 0 8px; }
.pdp-price { font-size: 1.6rem; font-weight: 800; margin: 6px 0 18px; }
.pdp-desc { color: var(--ink-soft); margin-bottom: 26px; }

.config { display: flex; flex-direction: column; gap: 18px; margin-bottom: 24px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; }
.field label .req { color: #d8584f; }
.field input[type='text'], .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  font-family: inherit; font-size: 0.98rem; background: #fff; color: var(--ink);
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--mint-deep); }
.field textarea { min-height: 84px; resize: vertical; }
.field .hint { color: var(--ink-soft); font-size: 0.82rem; margin-top: 4px; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #d8584f; }

.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; }
.qty button { width: 42px; height: 42px; border: none; background: var(--mint-tint); font-size: 1.2rem; cursor: pointer; color: var(--ink); }
.qty button:hover { background: var(--mint); }
.qty span { min-width: 46px; text-align: center; font-weight: 700; }

.pdp-cta { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.variant-status { font-size: 0.85rem; }
.variant-status.ok { color: var(--mint-deep); }
.variant-status.err { color: #d8584f; }

/* ---- Cart drawer --------------------------------------------------------- */
.drawer-overlay {
  position: fixed; inset: 0; background: rgba(31, 42, 36, 0.35); opacity: 0; visibility: hidden;
  transition: opacity 0.25s ease; z-index: 60;
}
.drawer-overlay.open { opacity: 1; visibility: visible; }
.drawer {
  position: fixed; top: 0; right: 0; height: 100%; width: min(420px, 92vw); background: #fff;
  box-shadow: var(--shadow-lg); transform: translateX(100%); transition: transform 0.28s ease;
  z-index: 61; display: flex; flex-direction: column;
}
.drawer.open { transform: translateX(0); }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 22px 22px 16px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { margin: 0; }
.drawer-close { background: none; border: none; font-size: 1.6rem; cursor: pointer; line-height: 1; color: var(--ink-soft); }
.drawer-items { flex: 1; overflow-y: auto; padding: 12px 22px; }
.cart-line { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.cart-line .thumb { width: 56px; height: 56px; border-radius: 10px; background: var(--mint-tint); object-fit: cover; }
.cart-line .ttl { font-weight: 700; font-size: 0.95rem; }
.cart-line .attrs { color: var(--ink-soft); font-size: 0.8rem; }
.cart-line .ln-price { font-weight: 700; }
.cart-line .ln-qty { display: inline-flex; align-items: center; gap: 8px; margin-top: 6px; }
.cart-line .ln-qty button { width: 26px; height: 26px; border-radius: 8px; border: 1px solid var(--line); background: #fff; cursor: pointer; }
.cart-line .remove { background: none; border: none; color: #d8584f; cursor: pointer; font-size: 0.8rem; margin-top: 6px; }
.cart-empty { text-align: center; color: var(--ink-soft); padding: 50px 20px; }
.drawer-foot { padding: 20px 22px; border-top: 1px solid var(--line); }
.drawer-foot .row { display: flex; justify-content: space-between; margin-bottom: 14px; font-weight: 700; font-size: 1.1rem; }
.drawer-foot .note { color: var(--ink-soft); font-size: 0.82rem; margin: 0 0 14px; }
.drawer-foot .clear { background: none; border: none; color: var(--ink-soft); cursor: pointer; text-decoration: underline; font-size: 0.85rem; display: block; margin: 12px auto 0; }

/* ---- Toasts -------------------------------------------------------------- */
.toast-wrap { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 80; display: flex; flex-direction: column; gap: 8px; }
.toast { background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 999px; box-shadow: var(--shadow-lg); font-weight: 600; font-size: 0.9rem; animation: toastin 0.25s ease; }
.toast.err { background: #d8584f; }
.toast.ok { background: var(--mint-deep); }
@keyframes toastin { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* ---- Footer -------------------------------------------------------------- */
.site-footer { background: var(--ink); color: #cfe0d8; padding: 50px 0 30px; margin-top: 40px; }
.footer-grid { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 24px; }
.site-footer a { color: #cfe0d8; }
.site-footer a:hover { color: #fff; }
.site-footer .brand { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.12); margin-top: 30px; padding-top: 18px; font-size: 0.85rem; color: #9fb4ab; }

/* ---- Admin --------------------------------------------------------------- */
.admin-shell { min-height: 100vh; background: var(--mint-tint); }
.admin-login {
  max-width: 380px; margin: 9vh auto; background: #fff; border-radius: var(--radius);
  padding: 36px; box-shadow: var(--shadow);
}
.admin-login h1 { font-size: 1.5rem; }
.admin-login .field { margin-bottom: 16px; }
.admin-login label { display: block; font-weight: 600; margin-bottom: 6px; }
.admin-login input { width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); font-family: inherit; font-size: 1rem; }
.admin-login input:focus { outline: none; border-color: var(--mint-deep); }
.login-error { color: #d8584f; font-size: 0.9rem; margin: 10px 0 0; }

.admin-bar { background: #fff; border-bottom: 1px solid var(--line); }
.admin-bar .nav { height: 64px; }
.admin-bar .who { color: var(--ink-soft); margin-right: 14px; }

.admin-main { padding: 30px 0 60px; }
.admin-tabs { display: flex; gap: 8px; margin-bottom: 22px; }
.admin-tab { background: #fff; border: 1px solid var(--line); padding: 9px 18px; border-radius: 999px; cursor: pointer; font-weight: 600; color: var(--ink-soft); }
.admin-tab.active { background: var(--mint); color: var(--ink); border-color: var(--mint); }

.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--line); font-size: 0.92rem; vertical-align: top; }
.table th { background: var(--mint-tint); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-soft); }
.table tr:last-child td { border-bottom: none; }
.table tbody tr:hover { background: #fafdfb; }

.pill { display: inline-block; padding: 3px 11px; border-radius: 999px; font-size: 0.75rem; font-weight: 700; }
.pill.paid { background: #fff2cc; color: #8a6d00; }
.pill.fulfilled { background: #d8f3e6; color: #1d7a52; }
.pill.cancelled { background: #f6dcda; color: #9c2b22; }
.pill.sent { background: #d8f3e6; color: #1d7a52; }
.pill.failed { background: #f6dcda; color: #9c2b22; }
.pill.pending, .pill.skipped { background: #e9eeec; color: #586b61; }

.switch { position: relative; display: inline-block; width: 46px; height: 26px; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; cursor: pointer; inset: 0; background: #cdd8d2; border-radius: 999px; transition: 0.2s; }
.slider::before { content: ''; position: absolute; height: 20px; width: 20px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: 0.2s; }
.switch input:checked + .slider { background: var(--mint-deep); }
.switch input:checked + .slider::before { transform: translateX(20px); }

/* Modal (order detail) */
.modal-overlay { position: fixed; inset: 0; background: rgba(31,42,36,0.4); display: none; align-items: center; justify-content: center; z-index: 70; padding: 20px; }
.modal-overlay.open { display: flex; }
.modal { background: #fff; border-radius: var(--radius); width: min(640px, 100%); max-height: 90vh; overflow-y: auto; box-shadow: var(--shadow-lg); }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 22px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; }
.modal-body { padding: 22px; }
.kv { display: grid; grid-template-columns: 140px 1fr; gap: 6px 14px; margin-bottom: 18px; }
.kv dt { color: var(--ink-soft); font-size: 0.85rem; }
.kv dd { margin: 0; font-weight: 600; }
.item-row { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; margin-bottom: 10px; }
.item-row .sku { font-family: monospace; background: var(--mint-tint); padding: 1px 7px; border-radius: 6px; font-size: 0.8rem; }
.attr-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.attr-chip { background: var(--mint-tint); border-radius: 8px; padding: 3px 9px; font-size: 0.78rem; }
.fulfill-form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 10px; }
.fulfill-form .full { grid-column: 1 / -1; }
.fulfill-form label { font-weight: 600; font-size: 0.85rem; display: block; margin-bottom: 5px; }
.fulfill-form input, .fulfill-form select { width: 100%; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); font-family: inherit; }
.checkrow { display: flex; align-items: center; gap: 8px; font-size: 0.9rem; }
.history { margin-top: 18px; }
.history h4 { margin: 0 0 8px; }
.history-item { font-size: 0.85rem; padding: 8px 0; border-bottom: 1px solid var(--line); color: var(--ink-soft); }

/* ---- Responsive ---------------------------------------------------------- */
@media (max-width: 880px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { order: -1; aspect-ratio: 16 / 11; }
  .pdp { grid-template-columns: 1fr; }
  .pdp-gallery { position: static; }
  .nav-links a:not(.cart-host) { display: none; }
  .fulfill-form { grid-template-columns: 1fr; }
}
