:root {
  --gincor-red: #c8102e;
  --gincor-red-dark: #970c22;
  --gincor-red-light: #e94f63;
  --ink: #1a1a1a;
  --muted: #6b6b6f;
  --bg: #f5f5f7;
  --card-bg: #ffffff;
  --border: #e4e4e7;
  --header-h: auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: inherit;
  -webkit-font-smoothing: antialiased;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

/* ---------- Header ---------- */
.site-header {
  background: linear-gradient(135deg, var(--gincor-red) 0%, var(--gincor-red-dark) 100%);
  color: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  flex: 0 0 auto;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 24px;
  display: flex;
  align-items: center;
}

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

.brand-logo {
  flex: 0 0 auto;
  height: 44px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.15));
}

.brand-text h1 {
  margin: 0;
  font-size: clamp(1.15rem, 2.4vw, 1.6rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.subtitle {
  margin: 4px 0 0;
  font-size: clamp(0.8rem, 1.4vw, 0.95rem);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.4;
  max-width: 720px;
}

/* ---------- Welcome ---------- */
.welcome-section {
  flex: 0 0 auto;
  background: var(--bg);
  padding: 32px 16px 8px;
}

.welcome-inner {
  max-width: 900px;
  margin: 0 auto;
}

.welcome-title {
  margin: 0 0 12px;
  font-size: clamp(1.3rem, 3vw, 1.75rem);
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.welcome-title::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin-top: 10px;
  border-radius: 2px;
  background: var(--gincor-red);
}

.welcome-lead {
  margin: 18px 0 20px;
  font-size: 1.02rem;
  line-height: 1.6;
  color: var(--ink);
  max-width: 720px;
}

.welcome-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 16px;
  margin-bottom: 18px;
}

.welcome-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-left: 4px solid var(--gincor-red);
  border-radius: 10px;
  padding: 18px 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.welcome-card h3 {
  margin: 0 0 10px;
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--gincor-red-dark);
}

.welcome-card p {
  margin: 0 0 10px;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--muted);
}

.welcome-card p:last-child {
  margin-bottom: 0;
}

.sample-questions {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sample-questions li {
  position: relative;
  padding: 10px 14px 10px 32px;
  background: var(--bg);
  border-radius: 8px;
  font-size: 0.92rem;
  color: var(--ink);
  line-height: 1.4;
}

.sample-questions li::before {
  content: "?";
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--gincor-red);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.welcome-footnote {
  margin: 4px 0 20px;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--muted);
}

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

/* ---------- Main / Chat ---------- */
.chat-main {
  flex: 0 0 auto;
  display: flex;
  padding: 8px 16px 24px;
  background: var(--bg);
}

.chat-wrapper {
  display: flex;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

.chat-frame-container {
  width: 100%;
  height: 80vh;
  min-height: 560px;
  max-height: 900px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  position: relative;
}

.chat-frame-container iframe {
  display: block;
  border: none;
  width: 100%;
  height: 100%;
}

/* ---------- Footer ---------- */
.site-footer {
  flex: 0 0 auto;
  text-align: center;
  padding: 10px 16px;
  font-size: 0.78rem;
  color: var(--muted);
  background: var(--bg);
}

.site-footer p {
  margin: 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .header-inner {
    padding: 16px 16px;
  }

  .brand {
    gap: 12px;
  }

  .brand-logo {
    height: 34px;
    max-width: 130px;
  }

  .welcome-section {
    padding: 24px 14px 4px;
  }

  .welcome-card {
    padding: 14px 16px;
  }

  .chat-main {
    padding: 6px 10px 18px;
  }

  .chat-frame-container {
    height: 70vh;
    min-height: 420px;
    border-radius: 10px;
  }

  .site-footer {
    font-size: 0.72rem;
    padding: 8px 12px;
  }
}

@media (max-width: 400px) {
  .brand-text h1 {
    font-size: 1.05rem;
  }
}
