:root {
  --bg: #0b0c10;
  --panel: #12141a;
  --panel-2: #171a21;
  --text: #e6e8ec;
  --muted: #aab2c0;
  --accent: #4f8cff;
  --accent-2: #00b894;
  --danger: #ff6b6b;
  --border: #272b35;
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, 'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
  background: linear-gradient(180deg, #0b0c10 0%, #0e1117 100%);
  color: var(--text);
  line-height: 1.6;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

.site-header {
  padding: 48px 0 24px;
}
.headline {
  margin: 0 0 12px;
  font-weight: 700;
  font-size: 28px;
  letter-spacing: -0.01em;
}
.subtitle {
  margin: 0;
  color: var(--muted);
}

.key-quote {
  margin: 16px 0 0;
  padding: 8px 0 8px 64px;
  position: relative;
}
.key-quote::before {
  content: "\201C"; /* left double quotation mark */
  position: absolute;
  left: 16px;
  top: 8px;
  font-size: 48px;
  line-height: 1;
  color: var(--accent);
  opacity: 0.35;
  pointer-events: none;
}
.key-quote p {
  margin: 0;
  color: var(--text);
}

main { padding: 12px 0 48px; }

.section-header { margin: 28px 0 16px; }
.section-header h2 {
  margin: 0 0 6px;
  font-size: 20px;
}
.section-sub {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

/* Invoice */
.invoice-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow);
}
.invoice-thumb {
  display: inline-flex;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  border-radius: 8px;
  overflow: hidden;
}
.invoice-thumb img {
  display: block;
  height: 140px;
  width: auto;
}
.invoice-actions { margin-left: auto; display: flex; gap: 8px; }
.button {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--panel-2);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
}
.button:hover { border-color: #3a4150; }
.button.link { text-decoration: none; display: inline-flex; align-items: center; }

/* Chat */
.chat-list { display: grid; gap: 12px; }
.message {
  display: grid;
  gap: 8px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  box-shadow: var(--shadow);
}
.message .meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.author {
  font-weight: 600;
}
.timestamp { color: var(--muted); font-size: 12px; }
.content { white-space: pre-wrap; }

.from-ja { border-left: 3px solid var(--accent); }
.from-ecogral { border-left: 3px solid var(--accent-2); }

/* Modal */
.modal[aria-hidden="true"] { display: none; }
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
}
.modal-content {
  position: absolute;
  inset: 40px 20px 40px 20px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  display: grid;
  grid-template-rows: auto 1fr;
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}
.modal-body {
  overflow: auto;
  padding: 12px;
}
.modal-body img { max-width: 100%; height: auto; display: block; margin: 0 auto; }
.icon-button {
  background: transparent;
  border: 0;
  color: var(--text);
  cursor: pointer;
  font-size: 20px;
}

.site-footer { padding: 28px 0; color: var(--muted); font-size: 12px; }

@media (max-width: 640px) {
  .invoice-card { flex-direction: column; align-items: stretch; }
  .invoice-thumb img { width: 100%; height: auto; }
  .invoice-actions { margin: 0; }
}


