/* ===== GRA Jewelry Site - Front-end Styles ===== */
:root {
  --gold: #a7947a;
  --gold-dark: #8a7660;
  --ink: #202020;
  --gray: #666;
  --light: #999;
  --line: #e8e4de;
  --bg: #ffffff;
  --bg-soft: #f7f5f2;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: "Georgia", "Times New Roman", serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 14px;
  line-height: 1.7;
}
a { text-decoration: none; color: var(--gold); }
img { max-width: 100%; display: block; }

.webbox { min-height: 100vh; display: flex; flex-direction: column; }

/* ---------- Header ---------- */
.header { border-bottom: 1px solid var(--line); background: #fff; position: sticky; top: 0; z-index: 100; }
.header-inner {
  max-width: 1200px; margin: 0 auto; padding: 0 20px;
  display: flex; align-items: center; gap: 40px; height: 84px;
}
.logo { display: flex; flex-direction: column; line-height: 1.2; }
.logo-mark {
  font-size: 34px; letter-spacing: 6px; font-weight: bold; color: var(--ink);
}
.logo-sub { font-size: 9px; letter-spacing: 1.5px; color: var(--gold); text-transform: uppercase; }

.menu { flex: 1; }
.menu ul { list-style: none; display: flex; gap: 8px; }
.menu li a {
  display: block; padding: 10px 18px; text-align: center; color: var(--ink);
  border-bottom: 2px solid transparent; transition: all .2s;
}
.menu li a em { display: block; font-style: normal; font-size: 10px; color: var(--light); letter-spacing: 1px; }
.menu li:hover a, .menu li.active a { color: var(--gold); border-bottom-color: var(--gold); }
.menu li:hover a em, .menu li.active a em { color: var(--gold); }

.header-search { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 20px; padding: 4px 6px 4px 14px; }
.header-search input { border: 0; outline: 0; width: 190px; font-size: 13px; color: var(--ink); background: transparent; }
.header-search input::placeholder { color: #bbb; }
.header-search button {
  border: 0; background: var(--gold); color: #fff; width: 30px; height: 30px;
  border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.header-search button:hover { background: var(--gold-dark); }

/* ---------- Banner ---------- */
.banner { position: relative; height: 460px; overflow: hidden; background: #111; }
.banner-slide {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  opacity: 0; transition: opacity 1s ease;
}
.banner-slide.current { opacity: 1; }
.banner-caption {
  position: absolute; left: 50%; bottom: 70px; transform: translateX(-50%);
  color: #fff; font-size: 30px; letter-spacing: 10px;
  text-shadow: 0 2px 12px rgba(0,0,0,.6); white-space: nowrap;
}
.banner-dots { position: absolute; bottom: 24px; left: 0; right: 0; text-align: center; }
.banner-dots span {
  display: inline-block; width: 34px; height: 4px; margin: 0 5px;
  background: rgba(255,255,255,.4); cursor: pointer; transition: background .3s;
}
.banner-dots span.current { background: var(--gold); }

/* ---------- Common content area ---------- */
.content { max-width: 1200px; margin: 0 auto; padding: 50px 20px 70px; width: 100%; flex: 1; }

.page-banner {
  background: linear-gradient(rgba(20,16,10,.55), rgba(20,16,10,.55)), var(--bg-soft) url('/static/images/banner2.png') center/cover;
  text-align: center; color: #fff; padding: 64px 20px;
}
.page-banner h1 { font-size: 30px; letter-spacing: 6px; }
.page-banner p { color: #e8ddcc; letter-spacing: 4px; margin-top: 6px; }

.section-head { text-align: center; margin: 56px 0 34px; }
.section-head h2 { font-size: 26px; letter-spacing: 4px; color: var(--ink); }
.section-head p { color: var(--gray); margin-top: 8px; }
.section-head h2::after {
  content: ""; display: block; width: 56px; height: 2px; background: var(--gold); margin: 12px auto 0;
}

/* ---------- Home search ---------- */
.home-search { max-width: 720px; margin: 0 auto; }
.home-search form {
  display: flex; align-items: center; gap: 12px;
  border: 1px solid var(--gold); border-radius: 40px; padding: 8px 10px 8px 22px;
  background: #fff; box-shadow: 0 6px 24px rgba(167,148,122,.15);
}
.home-search input { flex: 1; border: 0; outline: 0; font-size: 15px; background: transparent; }
.home-search input::placeholder { color: #bbb; }
.home-search button {
  border: 0; background: var(--gold); color: #fff; font-size: 14px; letter-spacing: 2px;
  padding: 10px 28px; border-radius: 30px; cursor: pointer; font-family: inherit;
}
.home-search button:hover { background: var(--gold-dark); }

/* ---------- Gem scroll display ---------- */
.roll-box { display: flex; align-items: center; gap: 14px; }
.roll-btn {
  flex: none; width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--line); background: #fff; color: var(--gold);
  font-size: 16px; cursor: pointer; transition: all .2s;
}
.roll-btn:hover { background: var(--gold); color: #fff; border-color: var(--gold); }
.roll-view { overflow: hidden; flex: 1; }
.roll-track { display: flex; gap: 24px; transition: transform .5s ease; will-change: transform; }
.gem-card { flex: 0 0 256px; text-align: center; }
.gem-card dt img {
  width: 100%; height: 190px; object-fit: cover; margin: 0 auto;
}
.gem-card dt { overflow: hidden; }
.gem-card dt img { transition: transform .4s; }
.gem-card:hover dt img { transform: scale(1.06); }
.gem-name { margin-top: 14px; font-size: 15px; letter-spacing: 2px; color: var(--ink); }
.gem-desc { margin-top: 6px; font-size: 12px; color: var(--gray); padding: 0 8px; }

/* ---------- About us ---------- */
.about-box { max-width: 860px; margin: 0 auto; }
.page-title { text-align: center; font-size: 26px; letter-spacing: 4px; margin-bottom: 30px; }
.page-title::after { content: ""; display: block; width: 56px; height: 2px; background: var(--gold); margin: 12px auto 0; }
.about-text p { margin-bottom: 18px; color: #444; font-size: 15px; text-indent: 2em; }

/* ---------- Certificate samples ---------- */
.sample-list { display: flex; flex-wrap: wrap; gap: 30px; justify-content: center; }
.sample-item { max-width: 520px; }
.sample-item img { border: 1px solid var(--line); box-shadow: 0 8px 30px rgba(0,0,0,.08); }
.sample-item figcaption { text-align: center; margin-top: 10px; color: var(--gray); }
.empty-tip { text-align: center; color: var(--light); padding: 40px; }

/* ---------- Contact us ---------- */
.contact-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 20px;
}
.contact-card {
  border: 1px solid var(--line); padding: 36px 20px; text-align: center; background: #fff;
  transition: all .25s;
}
.contact-card:hover { border-color: var(--gold); box-shadow: 0 10px 30px rgba(167,148,122,.18); transform: translateY(-4px); }
.contact-icon { font-size: 30px; color: var(--gold); margin-bottom: 12px; }
.contact-card h3 { font-size: 15px; letter-spacing: 2px; margin-bottom: 8px; }
.contact-card p { color: var(--gray); font-size: 13px; word-break: break-all; }

/* ---------- Query results ---------- */
.result-fail {
  max-width: 720px; margin: 0 auto 26px; text-align: center;
  background: #fdf3f2; border: 1px solid #f0c9c4; color: #c0392b;
  padding: 14px 20px; border-radius: 6px;
}
.cert-result { max-width: 900px; margin: 44px auto 0; border: 1px solid var(--line); background: #fff; }
.cert-head {
  display: flex; align-items: center; gap: 16px;
  padding: 22px 30px; border-bottom: 2px solid var(--gold); background: var(--bg-soft);
}
.cert-badge {
  width: 44px; height: 44px; border-radius: 50%; background: var(--gold); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 20px; flex: none;
}
.cert-head h2 { font-size: 20px; letter-spacing: 2px; }
.cert-head p { color: var(--gray); font-size: 13px; }
.cert-body { padding: 30px; display: flex; gap: 30px; }
.cert-photo { flex: 0 0 260px; }
.cert-photo img { border: 1px solid var(--line); width: 100%; height: 260px; object-fit: cover; }
.cert-table { flex: 1; border-collapse: collapse; width: 100%; align-self: flex-start; }
.cert-table td { padding: 9px 18px; font-size: 14px; }
.cert-table tr:nth-child(odd) { background: #f4f4f2; }
.cert-table td:first-child { width: 250px; color: var(--gray); }
.cert-table td:last-child { color: var(--ink); font-weight: bold; }

/* ---------- Cert section groups ---------- */
.cert-sections { flex: 1; display: flex; flex-direction: column; gap: 24px; }
.cert-section-title {
  font-size: 13px; font-weight: bold; letter-spacing: 2.5px;
  text-transform: uppercase; color: var(--gold);
  margin: 0 0 6px 0; padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.cert-sections .cert-table { width: 100%; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); background: #fafaf8; margin-top: auto; }
.footer-inner {
  max-width: 1200px; margin: 0 auto; padding: 22px 20px;
  display: flex; justify-content: space-between; color: var(--light); font-size: 12px;
  letter-spacing: 1px; flex-wrap: wrap; gap: 8px;
}

/* ---------- Mobile nav toggle (hidden on desktop) ---------- */
.menu-toggle { display: none; align-items: center; justify-content: center; }
.menu-toggle span,
.menu-toggle span::before,
.menu-toggle span::after {
  content: ""; display: block; width: 20px; height: 2px; background: var(--ink); position: relative;
}
.menu-toggle span::before { position: absolute; top: -6px; left: 0; }
.menu-toggle span::after { position: absolute; top: 6px; left: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .header-inner {
    flex-wrap: wrap; height: auto; padding: 10px 16px; gap: 10px; align-items: center;
  }
  .logo { order: 1; }
  .menu-toggle {
    display: flex; order: 2; margin-left: auto;
    width: 42px; height: 42px; border: 1px solid var(--line);
    background: #fff; border-radius: 8px; cursor: pointer;
  }
  .header-search { order: 3; width: 100%; margin-left: 0; }
  .header-search input { width: 100%; }
  .menu {
    order: 4; width: 100%; flex: none; display: none; border-top: 1px solid var(--line);
  }
  .menu.open { display: block; }
  .menu ul { flex-direction: column; gap: 0; }
  .menu li { border-bottom: 1px solid var(--line); }
  .menu li:last-child { border-bottom: 0; }
  .menu li a {
    padding: 14px 8px; display: flex; justify-content: space-between;
    align-items: baseline; border-bottom: 0;
  }
  .menu li a em { text-align: right; }
  .menu li:hover a, .menu li.active a { border-bottom-color: transparent; color: var(--gold); }

  .banner { height: 320px; }
  .contact-grid { grid-template-columns: repeat(2, 1fr); }
  .cert-body { flex-direction: column; }
  .cert-photo { flex: none; align-self: center; width: 100%; max-width: 280px; }
  .content { padding: 40px 16px 56px; }
}
@media (max-width: 560px) {
  .logo-mark { font-size: 26px; letter-spacing: 3px; }
  .logo-sub { font-size: 8px; }
  .banner { height: 220px; }
  .banner-caption { font-size: 16px; letter-spacing: 3px; bottom: 40px; white-space: normal; width: 86%; text-align: center; }
  .page-banner { padding: 44px 16px; }
  .page-banner h1 { font-size: 22px; letter-spacing: 3px; }
  .section-head { margin: 40px 0 26px; }
  .section-head h2 { font-size: 22px; }
  .contact-grid { grid-template-columns: 1fr; }
  .cert-table td:first-child { width: 110px; }
  .cert-table td { padding: 9px 12px; font-size: 13px; }
  .home-search button { padding: 10px 18px; }
  .gem-card { flex: 0 0 200px; }
  .gem-card dt img { height: 150px; }
  .footer-inner { flex-direction: column; text-align: center; }
  .about-text p { font-size: 14px; }
  .result-fail { font-size: 13px; }
}
