:root {
  /* Site-wide dark palette */
  --page: #090A0E;
  --ink: #EBE7DF;
  --muted: #888294;
  --line: #242530;
  --surface: #111219;
  --surface2: #191A24;
  --charcoal: #C9A050;
  --teal: #3AAEE8;
  --coral: #e05555;
  --green: #2a3d2a;
  --success: #4caf82;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
  --radius: 8px;

  /* SHINAI brand design system */
  --gold: #C9A050;
  --gold-light: #E2C470;
  --gold-dark: #8B6A22;
  --brand-blue: #3AAEE8;
  --brand-blue-dark: #1872B8;
  --platinum: #A6AEBB;
  --copper: #C47038;

  /* Dark surface tokens */
  --obsidian: #090A0E;
  --surface-d: #111219;
  --surface-d2: #191A24;
  --border-d: #242530;

  /* Dark text tokens */
  --text-primary-d: #EBE7DF;
  --text-secondary-d: #888294;

  /* Light surface tokens */
  --cream: #F5F2EB;
  --border-l: #DDD8CE;
  --text-primary-l: #19170F;
  --text-secondary-l: #68624F;

  /* Typography */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-ui: 'Space Grotesk', system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page);
  color: var(--ink);
  font-family: var(--font-ui);
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  font: inherit;
  letter-spacing: 0;
}

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

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

p {
  color: var(--muted);
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--ink);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 48px;
  height: 68px;
  border-bottom: 1px solid var(--border-d);
  background: rgba(9, 10, 14, 0.88);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand img {
  width: 38px;
  height: 38px;
  border-radius: 6px;
  object-fit: contain;
}

.brand span {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 0.12em;
  color: var(--gold);
  font-weight: 500;
  line-height: 1;
}

.brand small {
  display: none;
}

.nav {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.nav a,
.nav button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid var(--border-d);
  border-radius: var(--radius);
  background: transparent;
  color: var(--text-secondary-d);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.nav a:hover,
.nav button:hover {
  color: var(--text-primary-d);
  border-color: var(--border-d);
}

.nav form {
  margin: 0;
}

.button-primary {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--obsidian);
  font-weight: 600;
}

.button-primary:hover {
  opacity: 0.88;
}

.button-accent {
  border-color: var(--gold);
  background: transparent;
  color: var(--gold);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  font-size: 12px;
}

.button-danger {
  border-color: rgba(224, 85, 85, 0.4);
  color: var(--coral);
  background: transparent;
}

.button-muted {
  border-color: var(--line);
  background: var(--surface2);
  color: var(--muted);
  cursor: default;
}

.hero {
  position: relative;
  min-height: 620px;
  display: grid;
  align-items: center;
  padding: 90px 28px;
  background-position: center;
  background-size: cover;
  color: #ffffff;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(18, 18, 18, 0.58);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: min(980px, 100%);
  margin: 0 auto;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero h1,
.page-title h1 {
  margin: 0 0 18px;
  font-size: 3.4rem;
  line-height: 1.02;
}

.hero p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.12rem;
}

.hero-actions,
.section-actions,
.form-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 22px;
}

.alpha-banner {
  display: grid;
  gap: 10px;
  margin-bottom: 24px;
  padding: 20px;
  border: 1px solid rgba(201, 160, 80, 0.26);
  border-radius: var(--radius);
  background: rgba(201, 160, 80, 0.07);
  box-shadow: var(--shadow);
}

.alpha-banner h2,
.alpha-banner p {
  margin: 0;
}

.alpha-pill {
  width: fit-content;
  padding: 6px 10px;
  border: 1px solid rgba(58, 174, 232, 0.28);
  border-radius: var(--radius);
  background: rgba(58, 174, 232, 0.1);
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

fieldset:disabled {
  opacity: 0.58;
}

.upload-status {
  display: none;
  gap: 12px;
  align-items: start;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(201, 160, 80, 0.26);
  border-radius: var(--radius);
  background: rgba(201, 160, 80, 0.07);
  color: var(--ink);
}

.upload-status-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.upload-status-head strong {
  min-width: 0;
}

.upload-percent {
  color: var(--teal);
  font-size: 0.88rem;
  font-weight: 900;
}

.upload-status.is-visible {
  display: grid;
}

.upload-status.is-error {
  border-color: rgba(224, 85, 85, 0.35);
  background: rgba(224, 85, 85, 0.08);
}

.upload-status.is-error .upload-progress {
  display: none;
}

.upload-status strong,
.upload-status p {
  margin: 0;
}

.upload-status p {
  color: var(--muted);
}

.upload-progress {
  position: relative;
  height: 7px;
  overflow: hidden;
  border-radius: var(--radius);
  background: rgba(201, 160, 80, 0.18);
}

.upload-progress::after {
  content: "";
  position: absolute;
  inset: 0;
  width: 42%;
  border-radius: inherit;
  background: var(--teal);
  animation: upload-progress 1.1s ease-in-out infinite;
}

.upload-progress.is-determinate::after {
  width: var(--upload-progress, 0%);
  transform: none;
  animation: none;
}

.is-submitting button[type="submit"] {
  cursor: progress;
  opacity: 0.72;
}

.upload-busy {
  cursor: progress;
}

@keyframes upload-progress {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(250%);
  }
}

.section,
.page {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 76px 28px;
}

.section-header,
.page-title {
  max-width: 820px;
  margin-bottom: 30px;
}

.section-header h2,
.page-title h1,
.page-title h2 {
  color: var(--ink);
}

.title-edit-form {
  display: grid;
  gap: 6px;
  width: 100%;
  max-width: min(1180px, 100%);
}

.title-edit-form input {
  width: 100%;
  min-width: 0;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  padding: 7px 9px;
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1.02;
  text-overflow: ellipsis;
}

.title-edit-form input:hover,
.title-edit-form input:focus {
  border-color: var(--gold);
  background: var(--surface);
  outline: 0;
}

.title-edit-help {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.grid-three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product-card,
.panel,
.metric,
.list-item,
.auth-box {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  color: var(--ink);
}

.product-card,
.panel,
.auth-box {
  padding: 22px;
}

.product-card img {
  width: 100%;
  height: 210px;
  border-radius: 8px;
  object-fit: cover;
  margin-bottom: 18px;
}

.product-card h3,
.panel h2 {
  margin: 0 0 10px;
}

.metric {
  display: grid;
  align-content: start;
  min-width: 0;
  min-height: 124px;
  padding: 18px;
}

.metric strong {
  display: block;
  min-width: 0;
  font-size: 1.8rem;
  line-height: 1.08;
  overflow-wrap: anywhere;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
}

.annotix-page {
  width: min(1760px, 100%);
  padding-left: clamp(20px, 3vw, 56px);
  padding-right: clamp(20px, 3vw, 56px);
}

.annotix-page .page-title {
  max-width: none;
}

.annotix-page .page-title > p {
  max-width: 980px;
}

.annotix-grid {
  display: grid;
  gap: 20px;
  align-items: start;
}

.annotix-home-grid {
  grid-template-columns: minmax(360px, 0.72fr) minmax(0, 1.28fr);
}

.annotix-summary-grid {
  grid-template-columns: minmax(420px, 1fr) minmax(520px, 1fr);
}

.annotix-work-grid {
  grid-template-columns: minmax(360px, 0.58fr) minmax(0, 1.42fr);
}

.annotix-data-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.36fr) minmax(340px, 0.64fr);
  gap: 20px;
  align-items: start;
}

.list {
  display: grid;
  gap: 10px;
}

.list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px;
}

.list-item > a {
  display: grid;
  gap: 4px;
  flex: 1 1 220px;
  min-width: 0;
}

.list-item-stack {
  align-items: flex-start;
}

.list-item span {
  color: var(--muted);
  font-size: 0.88rem;
}

.list-item strong,
.list-item span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.inline-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  flex: 0 0 auto;
  justify-content: flex-end;
  margin-left: auto;
}

.inline-actions form {
  margin: 0;
}

.button-small {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 0.86rem;
}

.auth-page {
  min-height: calc(100vh - 73px);
  display: grid;
  place-items: center;
  padding: 42px 20px;
}

.auth-box {
  width: min(460px, 100%);
}

.field {
  display: grid;
  gap: 7px;
  margin-bottom: 14px;
}

.field label {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface2);
  padding: 10px 12px;
  color: var(--ink);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.field textarea {
  resize: vertical;
}

.check-line {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 12px 0;
  color: var(--muted);
  line-height: 1.45;
}

.check-line input {
  margin-top: 4px;
}

.radio-list {
  display: grid;
  gap: 4px;
  margin: 8px 0 16px;
}

.representative-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 340px);
  gap: 18px;
  align-items: start;
}

.representative-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
  min-width: 0;
}

.representative-option {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(112px, 1fr);
  gap: 12px;
  min-width: 0;
  min-height: 340px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.representative-option:hover {
  border-color: rgba(201, 160, 80, 0.45);
  transform: translateY(-1px);
}

.representative-option:has(input:checked) {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 160, 80, 0.15);
}

.representative-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 24px;
  height: 24px;
  margin: 0;
  accent-color: var(--teal);
}

.representative-preview {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(45deg, var(--surface2) 25%, transparent 25%),
    linear-gradient(-45deg, var(--surface2) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--surface2) 75%),
    linear-gradient(-45deg, transparent 75%, var(--surface2) 75%),
    var(--surface);
  background-position: 0 0, 0 10px, 10px -10px, -10px 0;
  background-size: 20px 20px;
  pointer-events: none;
}

.representative-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

.representative-selected-badge {
  position: absolute;
  right: 10px;
  top: 10px;
  display: none;
  padding: 6px 9px;
  border-radius: var(--radius);
  background: var(--gold);
  color: var(--obsidian);
  font-size: 0.78rem;
  font-weight: 900;
}

.representative-option:has(input:checked) .representative-selected-badge {
  display: inline-flex;
}

.representative-copy {
  display: grid;
  align-content: start;
  gap: 6px;
  min-width: 0;
}

.representative-copy strong {
  min-width: 0;
  font-size: 1.08rem;
  line-height: 1.25;
}

.representative-copy span {
  min-width: 0;
  color: var(--muted);
  line-height: 1.32;
  overflow-wrap: anywhere;
}

.representative-copy small {
  color: var(--muted);
  font-weight: 700;
}

.representative-choice-text {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 36px;
  margin-top: 4px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface2);
  color: var(--ink) !important;
  font-weight: 900;
}

.representative-option:has(input:checked) .representative-choice-text {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--obsidian) !important;
}

.representative-submit-panel {
  position: sticky;
  top: 92px;
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.representative-submit-panel h3 {
  margin: 0;
  font-size: 1.15rem;
}

.representative-submit-panel p {
  margin: 0;
}

.representative-submit-panel .button {
  width: 100%;
}

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 20px 0;
}

.error {
  padding: 12px;
  border: 1px solid rgba(224, 85, 85, 0.35);
  border-radius: var(--radius);
  background: rgba(224, 85, 85, 0.1);
  color: #f08080;
}

.notice {
  padding: 12px;
  border: 1px solid rgba(76, 175, 130, 0.35);
  border-radius: var(--radius);
  background: rgba(76, 175, 130, 0.1);
  color: var(--success);
}

.warning {
  padding: 12px;
  border: 1px solid rgba(201, 160, 80, 0.35);
  border-radius: var(--radius);
  background: rgba(201, 160, 80, 0.1);
  color: var(--gold);
}

.warning p,
.error p,
.notice p {
  margin: 0 0 8px;
}

.warning p:last-child,
.error p:last-child,
.notice p:last-child {
  margin-bottom: 0;
}

.feedback-list {
  margin: 8px 0 0;
  padding-left: 20px;
}

.feedback-list li + li {
  margin-top: 4px;
}

.upload-zone {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 20px;
  background: var(--surface2);
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 36px 48px;
  border-top: 1px solid var(--border-d);
  background: var(--obsidian);
  color: var(--text-secondary-d);
  font-size: 11px;
  letter-spacing: 0.04em;
}

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

.footer-brand img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  opacity: 0.8;
}

.footer-brand-name {
  font-family: var(--font-display);
  font-size: 17px;
  color: var(--gold);
  letter-spacing: 0.1em;
}

.footer-links {
  display: inline-flex;
  gap: 22px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.footer-links a {
  color: var(--text-secondary-d);
  font-size: 11px;
  letter-spacing: 0.04em;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--gold);
}

@media (max-width: 900px) {
  .site-header,
  .site-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .hero {
    min-height: 500px;
  }

  .hero h1,
  .page-title h1,
  .title-edit-form input {
    font-size: 2.4rem;
  }

  .grid,
  .grid-three,
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .hero-actions,
  .section-actions,
  .form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .nav a,
  .nav button {
    width: 100%;
  }

  .button {
    width: 100%;
  }

  .hero {
    min-height: 420px;
  }

  .hero h1,
  .page-title h1,
  .title-edit-form input {
    font-size: 2rem;
  }

  .hero,
  .section,
  .page {
    padding-left: 18px;
    padding-right: 18px;
  }
}

/* SHINAI home page dark template */
.template-hero {
  width: 100%;
  min-height: 700px;
  height: calc(100vh - 68px);
  padding: 0 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  position: relative;
  background: var(--obsidian);
}

.template-hero::before {
  content: none;
}

#particles-js {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

#particles-js canvas {
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.mesh-mark {
  position: absolute;
  left: max(24px, calc((100vw - 1180px) / 2));
  bottom: -30px;
  z-index: 1;
  width: min(430px, 42vw);
  opacity: 0.24;
  filter: grayscale(1) contrast(1.15);
}

.mesh-mark img {
  width: 100%;
  height: auto;
}

.template-container {
  position: relative;
  z-index: 2;
  width: min(1140px, 100%);
  margin: 0 auto;
}

.template-hero-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  align-items: center;
  min-height: 580px;
}

.template-caption {
  padding: 48px 30px;
  border-radius: var(--radius);
  color: #ffffff;
  text-align: left;
}

.template-caption h1 {
  margin: 0 0 20px;
  color: #ffffff;
  font-size: 3rem;
  line-height: 1.04;
}

.template-caption .circle {
  color: var(--gold);
}

.template-caption p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.08rem;
}

.template-caption .button {
  background: rgba(255, 255, 255, 0.95);
}

.template-caption .button-primary {
  border-color: var(--teal);
  background: var(--teal);
}

.template-section {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 78px 28px;
}

.template-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.template-icon-box {
  min-height: 100%;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.template-icon-box img {
  width: 92px;
  height: 92px;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 20px;
}

.template-icon-box h3 {
  margin: 0 0 10px;
  font-size: 1.25rem;
}

.feature-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.8fr) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
}

.feature-column {
  display: grid;
  gap: 18px;
}

.feature-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 12px 34px rgba(23, 23, 19, 0.08);
}

.feature-column.right .feature-row {
  grid-template-columns: auto minmax(0, 1fr);
}

.feature-row h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.feature-row p {
  margin: 0;
}

.feature-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  background: var(--teal);
  color: #ffffff;
  font-weight: 900;
}

.feature-center {
  display: grid;
  place-items: center;
  min-height: 360px;
}

.feature-center img {
  width: min(260px, 70%);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.template-band {
  padding-top: 34px;
}

.contact-hero {
  min-height: 380px;
  height: auto;
  padding: 88px 28px;
  background: linear-gradient(135deg, var(--surface-d2, #191A24) 0%, var(--obsidian) 100%);
}

.contact-hero::before {
  background:
    repeating-linear-gradient(90deg, rgba(201, 160, 80, 0.06) 0 1px, transparent 1px 88px),
    repeating-linear-gradient(0deg, rgba(201, 160, 80, 0.04) 0 1px, transparent 1px 88px);
}

.breadcrumbs {
  display: flex;
  gap: 10px;
  align-items: center;
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 18px 28px 0;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.breadcrumbs a {
  color: var(--gold);
}

.breadcrumbs a:hover {
  color: var(--gold-light);
}

.breadcrumbs span::before {
  content: "/";
  margin-right: 10px;
  color: var(--line);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.28fr);
  gap: 20px;
  align-items: start;
}

.contact-info-panel,
.contact-action-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.contact-info-panel {
  display: grid;
  gap: 0;
  overflow: hidden;
}

.contact-info-box {
  padding: 22px;
  border-bottom: 1px solid var(--line);
}

.contact-info-box:last-child {
  border-bottom: 0;
}

.contact-info-box h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.contact-info-box p {
  margin: 0;
}

.contact-info-box p + p {
  margin-top: 4px;
}

.contact-link {
  color: var(--teal);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.contact-action-panel {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.contact-action-card {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface2);
}

.contact-action-card-primary {
  background: rgba(201, 160, 80, 0.07);
  border-color: rgba(201, 160, 80, 0.25);
}

.contact-action-card h3 {
  margin: 0 0 8px;
  font-size: 1.35rem;
}

.contact-action-card p {
  margin-bottom: 16px;
}

.legal-section .section-header p {
  color: var(--muted);
}

.legal-layout {
  display: grid;
  grid-template-columns: minmax(240px, 0.34fr) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.legal-summary,
.legal-content {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.legal-summary {
  position: sticky;
  top: 90px;
  padding: 22px;
}

.legal-summary h3 {
  margin: 0 0 8px;
}

.legal-summary p {
  margin: 0 0 14px;
}

.legal-content {
  overflow: hidden;
}

.legal-block {
  padding: 24px;
  border-bottom: 1px solid var(--line);
}

.legal-block:last-child {
  border-bottom: 0;
}

.legal-block h3 {
  margin: 0 0 10px;
  font-size: 1.12rem;
}

.legal-block p {
  margin: 0;
}

.legal-block p + p {
  margin-top: 12px;
}

.legal-block a {
  color: var(--teal);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.legal-details {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
}

.legal-details div {
  display: grid;
  grid-template-columns: minmax(160px, 0.34fr) minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface2);
}

.legal-details dt {
  color: var(--muted);
  font-weight: 900;
}

.legal-details dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}

.portfolio-example-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.portfolio-example-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.portfolio-media-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.portfolio-media-pair figure {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface2);
}

.portfolio-media-pair img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.portfolio-media-pair figcaption {
  padding: 8px 10px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.portfolio-example-card h3 {
  margin: 0 0 8px;
  font-size: 1.18rem;
}

.portfolio-example-card p {
  margin: 0;
}

.video-demo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.video-demo-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.video-demo-frame {
  position: relative;
  width: min(100%, 360px);
  margin: 0 auto 16px;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface2);
}

.video-demo-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-demo-card h3 {
  margin: 0 0 8px;
  font-size: 1.18rem;
}

.video-demo-card p {
  margin: 0;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

@media (max-width: 980px) {
  .template-hero {
    min-height: 620px;
    height: auto;
    padding-top: 78px;
    padding-bottom: 54px;
  }

  .template-hero-grid,
  .feature-layout,
  .template-card-grid,
  .portfolio-example-grid,
  .video-demo-grid,
  .contact-grid,
  .legal-layout,
  .annotix-home-grid,
  .annotix-summary-grid,
  .annotix-work-grid,
  .annotix-data-workspace,
  .representative-form {
    grid-template-columns: 1fr;
  }

  .legal-summary {
    position: static;
  }

  .representative-submit-panel {
    order: -1;
    top: 84px;
    z-index: 4;
  }

  .template-hero-space {
    min-height: 160px;
  }

  .template-caption {
    padding: 24px 0;
    text-align: center;
  }

  .template-caption p {
    margin-left: auto;
    margin-right: auto;
  }

  .template-caption .hero-actions {
    justify-content: center;
  }

  .mesh-mark {
    left: 50%;
    top: 80px;
    bottom: auto;
    width: min(300px, 58vw);
    transform: translateX(-50%);
  }
}

@media (max-width: 560px) {
  .template-hero {
    min-height: 620px;
    padding-left: 18px;
    padding-right: 18px;
  }

  .template-caption h1 {
    font-size: 2rem;
  }

  .template-caption p {
    font-size: 1rem;
  }

  .feature-row,
  .feature-column.right .feature-row {
    grid-template-columns: 1fr;
  }

  .legal-details div {
    grid-template-columns: 1fr;
  }

  .representative-option {
    min-height: 320px;
    padding: 12px;
  }

  .representative-list {
    grid-template-columns: 1fr;
  }

  .portfolio-media-pair {
    grid-template-columns: 1fr;
  }

  .feature-index {
    order: -1;
  }
}

/* ─── SHINAI HOME PAGE DARK SECTIONS ─────────────────────────────────────── */

.home-page {
  background: var(--obsidian);
  color: var(--text-primary-d);
}

.hero-tag {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid rgba(201, 160, 80, 0.27);
  padding: 6px 16px;
  border-radius: 20px;
  margin-bottom: 32px;
  font-family: var(--font-ui);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(52px, 7vw, 92px);
  line-height: 1.03;
  color: var(--text-primary-d);
  margin: 0 0 20px;
  letter-spacing: -0.01em;
  font-weight: 500;
}

.hero-title span { color: var(--gold); }

.hero-sub {
  font-size: 17px;
  color: var(--text-secondary-d);
  max-width: 560px;
  line-height: 1.7;
  margin: 0 0 44px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: center;
}

.btn-gold {
  background: var(--gold);
  color: var(--obsidian);
  border: none;
  padding: 13px 34px;
  border-radius: 5px;
  font-size: 13px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  cursor: pointer;
  font-family: var(--font-ui);
  font-weight: 600;
  transition: opacity 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.btn-gold:hover { opacity: 0.88; }

.btn-outline {
  background: transparent;
  color: var(--text-primary-d);
  border: 1px solid var(--border-d);
  padding: 13px 34px;
  border-radius: 5px;
  font-size: 13px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  cursor: pointer;
  font-family: var(--font-ui);
  transition: border-color 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.btn-outline:hover { border-color: var(--text-secondary-d); }

.hero-divider {
  width: 100%;
  height: 1px;
  margin-top: 72px;
  background: linear-gradient(to right, transparent, var(--border-d), transparent);
}

.home-section {
  padding: 88px 60px;
  max-width: 1280px;
  margin: 0 auto;
}

.home-divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border-d) 30%, var(--border-d) 70%, transparent);
  margin: 0 60px;
}

.section-eyebrow {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
  font-family: var(--font-ui);
}

.section-heading {
  font-family: var(--font-display);
  font-size: clamp(30px, 3.5vw, 50px);
  color: var(--text-primary-d);
  margin: 0 0 10px;
  line-height: 1.1;
  font-weight: 500;
}

.section-body {
  font-size: 14px;
  color: var(--text-secondary-d);
  line-height: 1.7;
  max-width: 520px;
}

/* KPI cards */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 48px;
}

.kpi-card {
  background: var(--surface-d);
  border: 1px solid var(--border-d);
  border-radius: 10px;
  padding: 22px 22px 18px;
  position: relative;
  overflow: hidden;
}

.kpi-card-accent {
  position: absolute;
  top: 0; right: 0;
  width: 50px; height: 50px;
  border-radius: 0 10px 0 50px;
  opacity: 0.08;
}

.kpi-label {
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary-d);
  margin-bottom: 10px;
  font-family: var(--font-ui);
}

.kpi-value {
  font-family: var(--font-display);
  font-size: 42px;
  line-height: 1;
  color: var(--text-primary-d);
  margin-bottom: 4px;
}

.kpi-unit {
  font-size: 14px;
  font-weight: 500;
  margin-left: 2px;
  font-family: var(--font-ui);
}

.kpi-sub {
  font-size: 10px;
  color: var(--text-secondary-d);
  margin-top: 8px;
  font-family: var(--font-ui);
}

/* Charts grid */
.charts-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 36px;
}

.charts-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.chart-wrap {
  background: var(--surface-d);
  border: 1px solid var(--border-d);
  border-radius: 12px;
  overflow: hidden;
  position: relative;
}

/* Capability + features */
.capability-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  margin-bottom: 48px;
}

.feature-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  border: 1px solid var(--border-d);
  border-radius: 12px;
  overflow: hidden;
}

.feature-item {
  background: var(--surface-d);
  padding: 30px 26px;
  transition: background 0.2s;
}

.feature-item:hover { background: var(--surface-d2); }

.feature-num {
  font-size: 11px;
  letter-spacing: 0.06em;
  margin-bottom: 14px;
  font-family: var(--font-ui);
  font-weight: 500;
}

.feature-title {
  font-family: var(--font-display);
  font-size: 21px;
  color: var(--text-primary-d);
  margin-bottom: 8px;
  font-weight: 400;
}

.feature-desc {
  font-size: 12px;
  color: var(--text-secondary-d);
  line-height: 1.7;
}

/* Section header row (heading left, body right) */
.section-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 44px;
}

/* Platform feature layout (3-col: features | logo | features) */
.platform-feature-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(200px, 0.7fr) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
}

.platform-feature-col {
  display: grid;
  gap: 14px;
}

.platform-feature-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: start;
  padding: 18px 20px;
  border: 1px solid var(--border-d);
  border-radius: var(--radius);
  background: var(--surface-d);
}

.platform-feature-row-right {
  grid-template-columns: auto minmax(0, 1fr);
}

.platform-feature-title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--text-primary-d);
  font-weight: 400;
}

.platform-feature-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  border-radius: var(--radius);
  border: 1px solid rgba(201, 160, 80, 0.3);
  color: var(--gold);
  font-size: 12px;
  font-weight: 600;
  font-family: var(--font-ui);
  letter-spacing: 0.04em;
}

.platform-feature-center {
  display: grid;
  place-items: center;
  min-height: 320px;
}

.platform-feature-center img {
  width: min(220px, 70%);
  border-radius: var(--radius);
  opacity: 0.85;
  filter: drop-shadow(0 0 28px rgba(201, 160, 80, 0.18));
}

/* Products section */
.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 44px;
}

.product-tile {
  background: var(--surface-d);
  border: 1px solid var(--border-d);
  border-radius: 10px;
  padding: 28px 24px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.2s;
}

.product-tile:hover { border-color: rgba(201, 160, 80, 0.35); }

.product-tile-logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 18px;
}

.product-tile-name {
  font-family: var(--font-display);
  font-size: 24px;
  color: var(--text-primary-d);
  margin-bottom: 10px;
  font-weight: 400;
}

.product-tile-desc {
  font-size: 13px;
  color: var(--text-secondary-d);
  line-height: 1.65;
  margin-bottom: 22px;
}

@media (max-width: 980px) {
  .template-hero {
    padding-left: 28px;
    padding-right: 28px;
  }

  .kpi-row,
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .charts-2col,
  .capability-grid,
  .feature-strip,
  .platform-feature-layout {
    grid-template-columns: 1fr;
  }

  .platform-feature-center {
    display: none;
  }

  .section-header-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .home-section {
    padding: 64px 28px;
  }

  .home-divider {
    margin: 0 28px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    padding: 28px 28px;
  }
}

@media (max-width: 560px) {
  .kpi-row,
  .products-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-gold,
  .btn-outline {
    justify-content: center;
  }
}
