/* ==========================================================================
   德信專業牌照顧問 / Dixon Professional Licence Consultant
   Site-wide stylesheet
   ========================================================================== */

:root {
  --cream: #f7f3ea;
  --cream-alt: #efe9db;
  --ink: #2b2924;
  --ink-soft: #4a473f;
  --brand-dark: #1e1e1e;
  --accent-green: #3f7a4f;
  --accent-green-dark: #2f5f3c;
  --accent-gold: #b08d3f;
  --border: #e0d9c6;
  --card-bg: #ffffff;
  --max-width: 1080px;
  --radius: 10px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Noto Sans TC", "PingFang HK", "Microsoft JhengHei", "Helvetica Neue", Arial, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

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

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

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header ---------- */
.site-header {
  background: var(--brand-dark);
  color: #fff;
  padding: 10px 0;
}

.site-header .header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo {
  background: #fff;
  color: var(--brand-dark);
  font-weight: 800;
  letter-spacing: 1px;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: 4px;
  white-space: nowrap;
}

.brand-text h1 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
}

.brand-text p {
  margin: 2px 0 0;
  font-size: 12px;
  color: #cfcabb;
}

.header-contacts {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
  color: #e7e2d2;
}

.header-contacts a { color: #e7e2d2; }
.header-contacts a:hover { color: #fff; }

/* ---------- Nav ---------- */
.site-nav {
  background: var(--cream-alt);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
}

.site-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  max-width: var(--max-width);
  margin: 0 auto;
}

.site-nav a {
  display: block;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}

.site-nav a:hover,
.site-nav a.active {
  background: var(--brand-dark);
  color: #fff;
  text-decoration: none;
}

.nav-toggle {
  display: none;
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, #1e1e1e 0%, #2f5f3c 55%, #3f7a4f 100%);
  color: #fff;
  padding: 90px 0 70px;
  text-align: center;
}

.hero h1 {
  font-size: 34px;
  margin: 0 0 10px;
}

.hero p.subhead {
  font-size: 18px;
  margin: 0 0 22px;
  color: #f1eee2;
}

.btn {
  display: inline-block;
  background: var(--accent-green);
  color: #fff;
  padding: 12px 26px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 15px;
  border: none;
  cursor: pointer;
}

.btn:hover { background: var(--accent-green-dark); text-decoration: none; }

.btn-outline {
  background: transparent;
  border: 2px solid #fff;
  color: #fff;
}

.btn-outline:hover { background: #fff; color: var(--brand-dark); }

/* ---------- Sections / cards ---------- */
.section {
  padding: 56px 0;
}

.section-alt {
  background: var(--cream-alt);
}

.section h2 {
  font-size: 26px;
  margin: 0 0 26px;
  text-align: center;
}

.section h2 small {
  display: block;
  font-size: 14px;
  font-weight: 400;
  color: var(--ink-soft);
  margin-top: 6px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
}

.card h3 {
  margin: 0 0 10px;
  font-size: 17px;
  color: var(--accent-green-dark);
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

@media (max-width: 720px) {
  .two-col { grid-template-columns: 1fr; }
}

/* ---------- Licence category blocks ---------- */
.licence-block {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card-bg);
  padding: 26px;
  margin-bottom: 22px;
}

.licence-block h3 {
  font-size: 19px;
  color: var(--accent-green-dark);
  margin-top: 0;
  border-bottom: 2px solid var(--accent-gold);
  padding-bottom: 10px;
}

.licence-meta {
  font-size: 14px;
  color: var(--ink-soft);
  margin: 6px 0;
}

.licence-meta strong { color: var(--ink); }

.licence-block ol,
.licence-block ul {
  padding-left: 22px;
}

/* ---------- Tables ---------- */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 18px 0;
  background: var(--card-bg);
  font-size: 14px;
}

table caption {
  text-align: left;
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 8px;
  color: var(--accent-green-dark);
}

th, td {
  border: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
}

th {
  background: var(--cream-alt);
  font-weight: 700;
}

.table-wrap {
  overflow-x: auto;
  margin-bottom: 30px;
}

/* ---------- Tile grid (like Wix image tiles) ---------- */
.tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.tile {
  display: block;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 18px;
  text-align: center;
  font-weight: 700;
  color: var(--ink);
  transition: transform .15s ease, box-shadow .15s ease;
}

.tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0,0,0,.08);
  text-decoration: none;
  color: var(--accent-green-dark);
}

.tile-dark {
  background: var(--brand-dark);
  color: #fff;
  border-color: var(--brand-dark);
}

.tile-dark:hover { color: var(--accent-gold); }

/* ---------- Pricing ---------- */
.price-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
}

.price-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}

.price-card .name {
  font-weight: 700;
  margin-bottom: 8px;
  min-height: 44px;
}

.price-card .price {
  font-size: 20px;
  font-weight: 800;
  color: var(--accent-green-dark);
}

/* ---------- FAQ (accordion, no JS-dependency: <details>) ---------- */
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card-bg);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  padding: 16px 20px;
  font-weight: 700;
  list-style: none;
  position: relative;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 20px;
  top: 14px;
  font-size: 22px;
  color: var(--accent-green-dark);
}

.faq-item[open] summary::after { content: "\2212"; }

.faq-body {
  padding: 0 20px 20px;
}

.faq-body h4 {
  margin: 14px 0 6px;
  font-size: 14px;
  color: var(--accent-green-dark);
}

.faq-body p { margin: 0 0 10px; font-size: 15px; }

/* ---------- Forms ---------- */
form.contact-form {
  display: grid;
  gap: 14px;
  max-width: 560px;
}

form.contact-form label {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-soft);
  display: block;
  margin-bottom: 4px;
}

form.contact-form input,
form.contact-form textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
}

form.contact-form textarea { min-height: 120px; resize: vertical; }

form.contact-form button {
  justify-self: start;
}

.form-note {
  font-size: 12px;
  color: var(--ink-soft);
  margin-top: -6px;
}

/* ---------- Disclaimer box ---------- */
.disclaimer {
  background: var(--cream-alt);
  border-left: 4px solid var(--accent-gold);
  padding: 16px 20px;
  font-size: 13.5px;
  color: var(--ink-soft);
  border-radius: 0 6px 6px 0;
  margin: 30px 0;
}

/* ---------- Checklist ---------- */
.checklist-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

@media (max-width: 720px) {
  .checklist-cols { grid-template-columns: 1fr; }
}

.checklist-cols h3 { font-size: 17px; }
.checklist-cols.good h3 { color: var(--accent-green-dark); }
.checklist-cols.bad h3 { color: #a83c3c; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--brand-dark);
  color: #cfcabb;
  padding: 40px 0 24px;
  margin-top: 60px;
  text-align: center;
  font-size: 13px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.footer-links a {
  color: #fff;
  background: rgba(255,255,255,.08);
  padding: 10px 20px;
  border-radius: 24px;
  font-weight: 600;
}

.footer-links a:hover { background: var(--accent-green); text-decoration: none; }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.small-note { font-size: 12.5px; color: var(--ink-soft); }
.breadcrumb {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.breadcrumb a { color: var(--ink-soft); }

/* ---------- Mobile nav ---------- */
@media (max-width: 860px) {
  .site-nav ul {
    display: none;
    flex-direction: column;
  }
  .site-nav ul.open { display: flex; }
  .nav-toggle {
    display: block;
    background: none;
    border: none;
    font-size: 22px;
    padding: 10px 16px;
    cursor: pointer;
    color: var(--ink);
    width: 100%;
    text-align: left;
  }
  .site-nav a { padding: 14px 20px; }
}

@media (max-width: 520px) {
  .hero { padding: 60px 0 46px; }
  .hero h1 { font-size: 26px; }
}
