/* css/style.css — Jainson Marble Design System & Stylesheet */

:root {
  --ink: #07162c;
  --ink2: #0e2543;
  --gold: #b88a2d;
  --gold2: #d7b164;
  --cream: #f7f0e3;
  --paper: #fffaf0;
  --stone: #e8dece;
  --muted: #776b5f;
  --line: rgba(7, 22, 44, .14);
  --shadow: 0 22px 70px rgba(7, 22, 44, .18);
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-sans);
  background-color: var(--cream);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600'%3E%3Cfilter id='m'%3E%3CfeTurbulence type='turbulence' baseFrequency='0.018 0.042' numOctaves='5' seed='8' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.96 0 0 0 0 0.93 0 0 0 0 0.86 0 0 0 0.06 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23m)'/%3E%3C/svg%3E"),
    radial-gradient(circle at 25% 10%, rgba(215, 177, 100, .18), transparent 28%),
    linear-gradient(180deg, #fffaf0 0%, #efe3cf 100%);
  background-size: 600px 600px, cover, cover;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

/* Typography */
h1, h2, h3, h4,
.section-title, .dialog-title, .gallery-headline,
.spotlight-name, .process-step h3 {
  font-family: var(--font-serif);
  letter-spacing: .01em;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 600; line-height: 1.1; margin: 0; }
h2 { font-size: clamp(1.4rem, 3.5vw, 2.1rem); font-weight: 600; line-height: 1.2; margin: 0; }
h3 { font-size: 1.2rem; font-weight: 600; margin: 0; }

/* Gold Shimmer Animations */
@keyframes shimmer {
  0%   { background-position: -300% center; }
  100% { background-position:  300% center; }
}
.brand-title {
  font-family: var(--font-serif);
  background: linear-gradient(90deg, var(--gold) 0%, var(--gold2) 30%, #fff4c2 45%, var(--gold2) 55%, var(--gold) 100%);
  background-size: 300% auto;
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 5s linear infinite;
  font-size: 1rem; font-weight: 800; letter-spacing: .04em;
}
.h1-gold {
  background: linear-gradient(90deg, var(--gold2) 0%, #ffd97a 40%, var(--gold2) 60%, var(--gold) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 6s linear infinite;
  display: block; font-size: .6em; letter-spacing: .16em; margin-top: .2rem;
}

/* Scroll Fade Rise */
.fade-rise {
  opacity: 0; transform: translateY(24px);
  transition: opacity .65s ease, transform .65s ease;
}
.fade-rise.visible { opacity: 1; transform: none; }
.fade-rise.delay-1 { transition-delay: .12s; }
.fade-rise.delay-2 { transition-delay: .22s; }
.fade-rise.delay-3 { transition-delay: .32s; }

/* Buttons */
.btn {
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  border-radius: 4px;
  padding: .5rem .75rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  font-size: .68rem;
  transition: all .2s;
  display: inline-flex; align-items: center; justify-content: center; gap: .3rem;
}
.btn:hover { border-color: rgba(184, 138, 45, .65); }
.btn.primary {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: #081428; border-color: transparent;
}
.btn.dark {
  background: var(--ink); color: var(--paper); border-color: var(--ink);
}
.btn.danger {
  color: #8d1f14; background: rgba(141, 31, 20, .07); border-color: rgba(141, 31, 20, .25);
}
.btn.small { padding: .35rem .55rem; font-size: .62rem; }
.btn.ai {
  background: linear-gradient(135deg, #4a1d96, #7c3aed); color: #fff; border-color: transparent;
}
.btn.ai:hover { opacity: .88; }
.btn.ai:disabled { opacity: .45; cursor: wait; }

/* Form Inputs */
.input, .select, .textarea {
  width: 100%;
  background: rgba(255, 250, 240, .85);
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 4px;
  padding: .6rem .75rem;
  outline: none;
  font-size: .9rem;
}
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--gold); background: #fff;
}
.textarea { min-height: 80px; resize: vertical; }

/* Top Navigation Bar */
.topbar {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 250, 240, .96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav {
  max-width: 1600px; margin: 0 auto; padding: .6rem 1rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand { display: flex; align-items: center; gap: .6rem; cursor: pointer; flex-shrink: 0; }
.mark {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--ink); color: var(--gold2);
  display: grid; place-items: center;
  border: 2px solid var(--gold); font-weight: 700; font-size: .9rem;
}
.nav-links, .nav-actions { display: flex; gap: .5rem; align-items: center; }
.nav-links { margin-left: auto; }

/* Hero Section */
.hero {
  max-width: 1600px; margin: 0 auto; padding: 1.2rem 1rem;
  display: grid; grid-template-columns: 1fr; gap: 1.2rem; width: 100%;
}
@media (min-width: 768px) {
  .hero { grid-template-columns: minmax(0, 0.92fr) minmax(300px, 1.08fr); }
}
.hero-copy {
  background: linear-gradient(135deg, rgba(255, 250, 240, .95), rgba(239, 227, 207, .88));
  border: 1px solid rgba(184, 138, 45, .25); border-radius: 8px;
  padding: clamp(1.2rem, 3vw, 2.2rem); box-shadow: var(--shadow);
  display: flex; flex-direction: column; justify-content: center;
}
.eyebrow {
  color: var(--gold); font-weight: 800; letter-spacing: .15em;
  text-transform: uppercase; font-size: .7rem; margin-bottom: .6rem;
}
.hero-copy p {
  font-size: .95rem; color: var(--muted); line-height: 1.65; margin: .8rem 0 1.2rem;
}
.hero-actions { display: flex; gap: .6rem; flex-wrap: wrap; }
.hero-media {
  position: relative; border-radius: 8px; overflow: hidden;
  height: min(480px, 60vh); border: 1px solid rgba(184, 138, 45, .28);
  box-shadow: var(--shadow); background: var(--ink);
}
.hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-badge {
  position: absolute; right: 1rem; bottom: 1rem;
  background: rgba(7, 22, 44, .92); color: var(--paper);
  border: 1px solid rgba(215, 177, 100, .75); padding: .8rem .9rem;
  border-radius: 6px; max-width: 200px; font-size: .78rem; line-height: 1.4;
}

/* Trust Badges Bar */
.trust {
  max-width: 1600px; margin: .5rem auto 1.5rem; padding: 0 1rem;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: .8rem; width: 100%;
}
.trust-card {
  background: var(--ink); color: var(--paper); border-radius: 6px;
  padding: .85rem; border: 1px solid rgba(215, 177, 100, .35);
}
.trust-card strong {
  display: block; color: var(--gold2); font-size: .75rem;
  letter-spacing: .08em; text-transform: uppercase; margin-bottom: .25rem;
}
.trust-card span { color: rgba(255, 250, 240, .75); font-size: .78rem; line-height: 1.35; }

/* Spotlight Card */
.spotlight-card {
  display: grid; grid-template-columns: 1fr 1fr; min-height: 340px;
  border-radius: 12px; overflow: hidden; box-shadow: 0 16px 60px rgba(0,0,0,.22);
  margin-bottom: 2rem;
}
@media(max-width: 640px) { .spotlight-card { grid-template-columns: 1fr; } }
.spotlight-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.spotlight-copy {
  padding: 2.2rem; display: flex; flex-direction: column; justify-content: center;
  background: linear-gradient(135deg, var(--ink) 0%, #132035 100%);
  border-left: 3px solid var(--gold);
}
.spotlight-label { font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold2); margin-bottom: .5rem; }
.spotlight-name { font-size: clamp(1.4rem, 2.5vw, 2rem); color: #fff; margin: 0 0 .4rem; font-weight: 600; line-height: 1.2; }
.spotlight-price { font-size: 1.2rem; color: var(--gold2); margin-bottom: .9rem; font-weight: 600; }
.spotlight-desc { color: rgba(255,255,255,.6); font-size: .83rem; line-height: 1.65; margin-bottom: 1.4rem; }

/* Process Section */
.process-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; margin-top: 1.5rem;
}
@media(max-width: 640px) { .process-grid { grid-template-columns: 1fr; } }
.process-step {
  text-align: center; padding: 1.6rem 1.2rem; background: rgba(255,255,255,.6);
  border: 1px solid var(--line); border-radius: 12px;
  transition: transform .3s ease, box-shadow .3s ease;
}
.process-step:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.process-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 50%; background: var(--gold);
  color: #fff; font-size: .72rem; font-weight: 700; margin-bottom: .8rem;
}
.process-icon { font-size: 2.2rem; display: block; margin-bottom: .6rem; }

/* Sticky Filter Bar */
.sticky-filters {
  position: sticky; top: 62px; z-index: 30;
  background: rgba(255, 250, 240, .96); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line); padding: .8rem 1rem; display: none;
}
.sticky-filters.active { display: block; }
.sticky-filters-content {
  max-width: 1600px; margin: 0 auto; display: grid;
  grid-template-columns: 1fr 1fr auto auto auto; gap: .5rem; align-items: center;
}
@media(max-width: 640px) { .sticky-filters-content { grid-template-columns: 1fr 1fr; } }

/* Section Container */
.section { max-width: 1600px; margin: 0 auto; padding: 1.5rem 1rem; width: 100%; }
.section-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 1rem; margin-bottom: 1rem; flex-wrap: wrap;
}
.filters {
  display: grid; grid-template-columns: minmax(150px, 1fr) repeat(2, minmax(120px, .8fr)) auto;
  gap: .6rem; margin-bottom: 1.2rem; align-items: center;
}
@media(max-width: 640px) { .filters { grid-template-columns: 1fr; } }

/* Product Grid & Cards */
.grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 1rem;
}
.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px;
  overflow: hidden; box-shadow: 0 12px 40px rgba(7, 22, 44, .08);
  transition: transform .2s, border-color .2s; cursor: pointer; position: relative;
}
.card:hover { transform: translateY(-4px); border-color: rgba(184, 138, 45, .55); }
.card.is-featured {
  box-shadow: 0 0 0 1px rgba(184,138,45,.4), 0 8px 30px rgba(0,0,0,.12), 0 0 55px rgba(215,177,100,.2);
}
.thumb { aspect-ratio: 4 / 5; background: var(--stone); position: relative; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s; }
.card:hover .thumb img { transform: scale(1.04); }
.tag {
  position: absolute; left: .5rem; top: .5rem; background: rgba(7, 22, 44, .9);
  color: var(--gold2); border-radius: 3px; padding: .2rem .4rem; font-size: .55rem;
  letter-spacing: .08em; text-transform: uppercase;
}
.sold {
  position: absolute; right: .5rem; top: .5rem; background: rgba(141, 31, 20, .92);
  color: white; border-radius: 3px; padding: .2rem .4rem; font-size: .55rem;
  letter-spacing: .08em; text-transform: uppercase;
}
.card-body { padding: .85rem; }
.kicker { color: var(--gold); font-weight: 800; font-size: .65rem; letter-spacing: .1em; text-transform: uppercase; margin-bottom: .2rem; }
.name { font-weight: 800; font-size: .95rem; line-height: 1.3; margin-bottom: .3rem; }
.meta { display: flex; gap: .3rem; flex-wrap: wrap; margin: .4rem 0; }
.chip { border: 1px solid var(--line); background: rgba(7, 22, 44, .035); color: var(--muted); border-radius: 99px; padding: .15rem .45rem; font-size: .7rem; }
.price { font-weight: 900; color: var(--ink2); font-size: 1.05rem; margin-bottom: .6rem; }
.card-actions { display: flex; gap: .35rem; flex-wrap: wrap; }

/* Skeleton Loader */
@keyframes skeleton-shimmer { 0% { background-position: -400px 0; } 100% { background-position: 400px 0; } }
.skeleton-card { border-radius: 10px; overflow: hidden; background: var(--stone); border: 1px solid var(--line); }
.skeleton-thumb {
  height: 220px; background: linear-gradient(90deg, var(--stone) 25%, #e0d5c4 50%, var(--stone) 75%);
  background-size: 800px 100%; animation: skeleton-shimmer 1.6s infinite;
}
.skeleton-body { padding: .9rem; }
.skeleton-line {
  height: 12px; border-radius: 6px; margin-bottom: .55rem;
  background: linear-gradient(90deg, #ddd0bc 25%, #ede4d4 50%, #ddd0bc 75%);
  background-size: 800px 100%; animation: skeleton-shimmer 1.6s infinite;
}

/* Pagination */
.pagination { display: flex; justify-content: center; gap: .5rem; margin: 2rem 0; flex-wrap: wrap; }
.pagination button {
  padding: .5rem .8rem; border: 1px solid var(--line); background: var(--paper);
  color: var(--ink); border-radius: 4px; font-weight: 700; transition: all .2s;
}
.pagination button.active { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* Material Comparison Guide */
.material-guide { margin: 1rem 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.material-guide summary {
  padding: .7rem .9rem; cursor: pointer; font-size: .82rem; font-weight: 600;
  background: var(--stone); list-style: none; display: flex; align-items: center; justify-content: space-between;
}
.material-guide summary::after { content: '﹀'; font-size: .75rem; }
.material-guide[open] summary::after { content: '︿'; }
.material-compare { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; padding: .8rem; }
@media (max-width: 500px) { .material-compare { grid-template-columns: 1fr; } }
.mat-item { padding: .7rem; border-radius: 6px; border: 1px solid var(--line); font-size: .75rem; }
.mat-item h5 { font-family: var(--font-serif); font-size: .88rem; margin: 0 0 .3rem; }
.mat-item p { color: var(--muted); margin: 0; line-height: 1.5; }

/* Related Products */
.related-section { margin-top: 1.4rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.related-grid { display: flex; gap: .6rem; overflow-x: auto; padding-bottom: .4rem; }
.related-card { flex: 0 0 110px; border-radius: 8px; overflow: hidden; cursor: pointer; border: 1px solid var(--line); transition: transform .2s; }
.related-card:hover { transform: translateY(-3px); }
.related-card img { width: 100%; height: 80px; object-fit: cover; display: block; background: var(--stone); }
.related-card-name { padding: .3rem .4rem; font-size: .68rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.related-card-price { padding: 0 .4rem .4rem; font-size: .68rem; color: var(--gold); font-weight: 700; }

/* Modal & Drawers */
.modal {
  position: fixed; inset: 0; z-index: 90; display: none; align-items: center; justify-content: center;
  padding: 1rem; background: rgba(7, 22, 44, .72); backdrop-filter: blur(8px); overflow-y: auto;
}
.modal.open { display: flex; }
.dialog {
  width: min(90vw, 700px); max-height: 90vh; overflow-y: auto; background: var(--paper);
  border-radius: 8px; border: 1px solid rgba(184, 138, 45, .4); box-shadow: var(--shadow); margin: auto;
}
.dialog-head {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: .9rem 1rem; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--paper); z-index: 2;
}
.dialog-title { font-weight: 900; letter-spacing: .08em; text-transform: uppercase; color: var(--ink); font-size: .95rem; }
.dialog-body { padding: 1rem; }
.dialog-foot {
  padding: .8rem 1rem; border-top: 1px solid var(--line); display: flex; justify-content: flex-end;
  gap: .5rem; flex-wrap: wrap; background: var(--paper); position: sticky; bottom: 0;
}
.detail-grid { display: grid; grid-template-columns: minmax(280px, .9fr) 1fr; gap: 1.2rem; }
@media(max-width: 640px) { .detail-grid { grid-template-columns: 1fr; } }
.detail-img { width: 100%; border-radius: 6px; background: var(--stone); max-height: 60vh; object-fit: cover; cursor: zoom-in; }

/* Cart Drawer Rows */
.cart-row { display: grid; grid-template-columns: 50px 1fr auto; gap: .6rem; align-items: start; padding: .6rem 0; border-bottom: 1px solid var(--line); }
.cart-row img { width: 50px; height: 60px; object-fit: cover; border-radius: 4px; background: var(--stone); }
.qty { display: flex; align-items: center; gap: .3rem; }

/* Mobile Bottom Navigation Bar */
.mobile-nav {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
  background: var(--ink); border-top: 1px solid rgba(255,255,255,.1);
  grid-template-columns: repeat(5, 1fr); box-shadow: 0 -4px 20px rgba(0,0,0,.25);
}
@media (max-width: 680px) {
  .mobile-nav { display: grid; }
  .wa-sticky { display: none !important; }
  body { padding-bottom: 60px; }
}
.mobile-nav-btn {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: .5rem .2rem; background: none; border: none; color: rgba(255,255,255,.5);
  font-size: .6rem; gap: .18rem; transition: color .2s;
}
.mobile-nav-btn .mn-icon { font-size: 1.2rem; line-height: 1; }
.mobile-nav-btn.active, .mobile-nav-btn:hover { color: var(--gold2); }
.mobile-nav-btn.wa-btn { color: #4cda7a; }

/* Sticky WhatsApp Bar */
@keyframes wa-pulse {
  0%,100%{ box-shadow:0 4px 20px rgba(37,211,102,.4),0 0 0 0 rgba(37,211,102,.35); }
  60% { box-shadow:0 4px 20px rgba(37,211,102,.4),0 0 0 10px rgba(37,211,102,0); }
}
.wa-sticky {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 80;
  background: #25d366; color: #fff; text-align: center; padding: .8rem;
  font-weight: 600; font-size: .88rem; cursor: pointer; box-shadow: 0 -3px 16px rgba(0,0,0,.14);
}
@media(max-width: 640px) { .wa-sticky { display: block; } }
[data-whatsapp-float] { animation: wa-pulse 2.5s ease infinite !important; }

/* Customer Showcase Gallery */
.gallery-section { padding: 3rem 0 3.5rem; overflow: hidden; }
.gallery-eyebrow { text-align: center; font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); font-weight: 700; margin-bottom: .5rem; }
.gallery-headline { text-align: center; font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 800; color: var(--ink); margin: 0 auto .3rem; }
.gallery-sub { text-align: center; color: var(--muted); font-size: .88rem; margin: 0 auto 2rem; max-width: 400px; }

/* Desktop Tilt Grid */
.gallery-float { display: flex; gap: .85rem; justify-content: center; align-items: flex-start; padding: 0 1rem 2rem; }
.gallery-col { display: flex; flex-direction: column; gap: .85rem; flex: 0 0 auto; width: 160px; }
.gallery-col:nth-child(2) { transform: translateY(40px); }
.gallery-col:nth-child(3) { transform: translateY(-15px); }
.gallery-col:nth-child(4) { transform: translateY(60px); }
.gallery-col:nth-child(5) { transform: translateY(20px); }
.gallery-card {
  border-radius: 12px; overflow: hidden; cursor: zoom-in; box-shadow: 0 4px 18px rgba(0,0,0,.14);
  transition: transform .3s ease, box-shadow .3s ease;
}
.gallery-card:hover { transform: scale(1.06) !important; box-shadow: 0 14px 40px rgba(0,0,0,.22); z-index: 10; position: relative; }
.gallery-card img { width: 100%; display: block; object-fit: cover; }

/* Mobile Touch Swipe Carousel */
.gallery-swipe { display: none; padding: 0 1.2rem; }
.swipe-stage { position: relative; border-radius: 16px; overflow: hidden; box-shadow: 0 10px 40px rgba(0,0,0,.18); touch-action: pan-y; }
.swipe-stage img { width: 100%; display: block; object-fit: cover; aspect-ratio: 4/3; pointer-events: none; }
.swipe-counter { position: absolute; bottom: .6rem; right: .8rem; background: rgba(0,0,0,.5); color: #fff; font-size: .7rem; padding: .2rem .5rem; border-radius: 20px; }
.swipe-dots { text-align: center; margin: .9rem 0 .5rem; }
.swipe-dot { display: inline-block; height: 7px; border-radius: 4px; background: var(--line); margin: 0 3px; transition: width .25s ease, background .25s ease; width: 7px; }
.swipe-dot.active { width: 22px; background: var(--gold); }
@media (max-width: 700px) { .gallery-float { display: none; } .gallery-swipe { display: block; } }

/* Lightbox Pinch-Zoom Overlay */
.zoom-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.93); z-index: 200; display: none;
  flex-direction: column; align-items: center; justify-content: center;
}
.zoom-overlay.open { display: flex; }
.zoom-close-btn {
  position: absolute; top: 14px; right: 18px; background: rgba(255,255,255,.15); border: none;
  color: #fff; font-size: 1.3rem; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; z-index: 2;
  display: flex; align-items: center; justify-content: center;
}
.zoom-container { width: 92vw; height: 88vh; overflow: hidden; display: flex; align-items: center; justify-content: center; cursor: zoom-in; }
.zoom-img { max-width: 92vw; max-height: 88vh; object-fit: contain; transform-origin: center center; user-select: none; border-radius: 4px; }
.zoom-hint { position: absolute; bottom: 14px; color: rgba(255,255,255,.5); font-size: .75rem; pointer-events: none; }

/* AI Floating Chatbot Widget */
.chat-bubble {
  position: fixed; bottom: 1.4rem; right: 1.4rem; z-index: 80; width: 52px; height: 52px; border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), var(--gold2)); border: none;
  box-shadow: 0 6px 24px rgba(7,22,44,.28); font-size: 1.3rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: transform .2s;
}
.chat-bubble:hover { transform: scale(1.08); }
.chat-panel {
  position: fixed; bottom: 5rem; right: 1.4rem; z-index: 80; width: min(360px, calc(100vw - 2rem));
  height: 450px; background: var(--paper); border: 1px solid rgba(184,138,45,.4);
  border-radius: 12px; box-shadow: var(--shadow); display: none; flex-direction: column; overflow: hidden;
}
.chat-panel.open { display: flex; }
.chat-head { background: var(--ink); color: var(--paper); padding: .7rem .9rem; display: flex; justify-content: space-between; align-items: center; }
.chat-messages { flex: 1; overflow-y: auto; padding: .75rem; display: flex; flex-direction: column; gap: .55rem; }
.chat-msg { max-width: 85%; padding: .55rem .75rem; border-radius: 10px; font-size: .82rem; line-height: 1.4; }
.chat-msg.user { align-self: flex-end; background: var(--ink); color: var(--paper); border-bottom-right-radius: 2px; }
.chat-msg.bot { align-self: flex-start; background: var(--stone); color: var(--ink); border-bottom-left-radius: 2px; }
.chat-foot { padding: .6rem; border-top: 1px solid var(--line); display: flex; gap: .4rem; }

/* Admin Dashboard Tabs & Components */
.admin-tabs { display: grid; grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); gap: .5rem; margin-bottom: 1.2rem; border-bottom: 2px solid var(--line); padding-bottom: .8rem; }
.admin-tabs button { padding: .6rem .8rem; border: 1px solid transparent; background: transparent; color: var(--muted); border-radius: 4px 4px 0 0; font-weight: 700; font-size: .75rem; text-transform: uppercase; }
.admin-tabs button.active { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.admin-tab-content { display: none; }
.admin-tab-content.active { display: block; }
.attempts-bar { height: 4px; background: rgba(141,31,20,.12); border-radius: 2px; overflow: hidden; margin: .5rem 0; }
.attempts-fill { height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold2)); border-radius: 2px; transition: width .4s ease; }

/* Toast Notifications */
.toast {
  position: fixed; left: 50%; bottom: 1.5rem; transform: translateX(-50%); z-index: 300;
  background: var(--ink); color: var(--paper); border: 1px solid rgba(215, 177, 100, .45);
  border-radius: 6px; padding: .7rem 1.1rem; display: none; font-size: .88rem; box-shadow: var(--shadow);
}
.toast.show { display: block; }

/* Footer */
.footer { background: var(--ink); color: var(--paper); border-top: 4px solid var(--gold); margin-top: auto; }
.footer-inner { max-width: 1600px; margin: 0 auto; padding: 1.5rem 1rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.5rem; }
.footer h3, .footer h4 { color: var(--gold2); margin: 0 0 .5rem; font-size: .95rem; }
.footer p, .footer a { color: rgba(255, 250, 240, .75); line-height: 1.5; text-decoration: none; display: block; margin: .2rem 0; font-size: .88rem; }
