/* =============================================
   BLACK BUTLER — Public Site
   Dark gothic premium — bordeaux accent
   ============================================= */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0c0c0c;
  --bg-card: #111;
  --bg-input: #0e0e0e;
  --text-primary: #ebebeb;
  --text-secondary: #d8d8d8;
  --text-muted: #555;
  --border: #1c1c1c;
  --border-input: #242424;
  --accent: #8b2a3a;
  --accent-hover: #a33345;
  --radius: 2px;
  --font-serif: 'Times New Roman', Georgia, serif;
  --font-sans: system-ui, -apple-system, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
}

/* ---- NAV ---- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  height: 56px;
  background: rgba(12,12,12,0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--font-serif);
  font-size: 13px;
  letter-spacing: 4px;
  color: var(--text-primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 10px;
  letter-spacing: 2px;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text-primary); }

.btn-nav-outline {
  border: 1px solid #2a2a2a !important;
  color: var(--text-secondary) !important;
  padding: 6px 14px;
  border-radius: var(--radius);
  font-size: 9px !important;
  letter-spacing: 2px !important;
  transition: border-color 0.2s, color 0.2s !important;
}
.btn-nav-outline:hover {
  border-color: #444 !important;
  color: var(--text-primary) !important;
}

/* ---- SECTION HERO ---- */
.section-hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px 40px;
  gap: 32px;
}

.hero-content {
  text-align: center;
  max-width: 600px;
}

.agent-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 9px;
  letter-spacing: 3px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.status-dot {
  width: 6px;
  height: 6px;
  background: #2a7a2a;
  border-radius: 50%;
  display: inline-block;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 400;
  letter-spacing: 1px;
  color: var(--text-primary);
  line-height: 1.2;
  margin-bottom: 12px;
}

.hero-sub {
  font-size: 13px;
  color: var(--text-muted);
  letter-spacing: 1px;
}

/* ---- CHAT WINDOW ---- */
.chat-window {
  width: 100%;
  max-width: 680px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 380px;
  box-shadow: 0 0 60px rgba(139,42,58,0.06);
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: #0e0e0e;
}

.chat-dot-red {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
}

.chat-title {
  font-size: 9px;
  letter-spacing: 3px;
  color: var(--text-muted);
  flex: 1;
}

.chat-status-online {
  width: 6px;
  height: 6px;
  background: #2a7a2a;
  border-radius: 50%;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 260px;
  max-height: 380px;
}

.chat-messages::-webkit-scrollbar { width: 3px; }
.chat-messages::-webkit-scrollbar-track { background: transparent; }
.chat-messages::-webkit-scrollbar-thumb { background: #2a2a2a; border-radius: 2px; }

.msg { display: flex; gap: 10px; align-items: flex-start; }
.msg-agent { justify-content: flex-start; }
.msg-user { justify-content: flex-end; flex-direction: row-reverse; }

.msg-avatar {
  width: 28px;
  height: 28px;
  background: var(--accent);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  font-family: var(--font-serif);
  letter-spacing: 1px;
  color: #f0f0f0;
  flex-shrink: 0;
}

.msg-bubble {
  background: #151515;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 14px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 80%;
}

.msg-bubble-user {
  background: #1a0a0d;
  border-color: #2a1218;
  color: var(--text-secondary);
}

/* typing indicator */
.typing-indicator span {
  display: inline-block;
  width: 4px; height: 4px;
  background: var(--text-muted);
  border-radius: 50%;
  margin: 0 1px;
  animation: blink 1.2s infinite;
}
.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 0%,80%,100% { opacity: 0.2; } 40% { opacity: 1; } }

.chat-input-row {
  display: flex;
  border-top: 1px solid var(--border);
}

.chat-input-row input {
  flex: 1;
  background: var(--bg-input);
  border: none;
  outline: none;
  padding: 14px 16px;
  font-size: 13px;
  color: var(--text-primary);
  font-family: var(--font-sans);
}

.chat-input-row input::placeholder { color: #333; }

.chat-input-row button {
  background: var(--accent);
  border: none;
  padding: 0 20px;
  color: #f0f0f0;
  font-size: 9px;
  letter-spacing: 2px;
  cursor: pointer;
  transition: background 0.2s;
  font-family: var(--font-sans);
}
.chat-input-row button:hover { background: var(--accent-hover); }
.chat-input-row button:disabled { background: #2a2a2a; cursor: not-allowed; }

.scroll-hint {
  font-size: 10px;
  letter-spacing: 3px;
  color: #333;
  animation: fadeUpDown 2s ease-in-out infinite;
}
@keyframes fadeUpDown {
  0%,100% { transform: translateY(0); opacity: 0.4; }
  50% { transform: translateY(4px); opacity: 0.8; }
}

/* ---- FEATURES ---- */
.section-features {
  padding: 80px 40px;
  max-width: 1100px;
  margin: 0 auto;
}

.section-label {
  font-size: 9px;
  letter-spacing: 4px;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.feature-card {
  padding: 28px 24px;
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}
.feature-card:hover { background: #141414; }

.feat-icon {
  font-size: 20px;
  display: block;
  margin-bottom: 12px;
  filter: grayscale(0.3);
}

.feature-card h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ---- PRICING ---- */
.section-pricing {
  padding: 80px 40px;
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
}

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

.price-amount {
  font-family: var(--font-serif);
  font-size: 52px;
  color: var(--text-primary);
  letter-spacing: -1px;
  margin-bottom: 4px;
}

.price-period {
  font-size: 18px;
  color: var(--text-muted);
}

.price-features {
  list-style: none;
  margin: 24px 0;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.price-features li {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 8px 0;
  border-bottom: 1px solid #161616;
}

/* ---- BUTTONS ---- */
.btn-accent {
  display: inline-block;
  background: var(--accent);
  color: #f0f0f0;
  border: none;
  border-radius: var(--radius);
  padding: 12px 28px;
  font-size: 10px;
  letter-spacing: 2px;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s;
  font-family: var(--font-sans);
  margin-top: 8px;
}
.btn-accent:hover { background: var(--accent-hover); }
.btn-full { width: 100%; text-align: center; }

/* ---- REGISTER FORM ---- */
.section-form {
  padding: 80px 40px;
  max-width: 460px;
  margin: 0 auto;
}

.register-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 9px;
  letter-spacing: 2px;
  color: var(--text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg-input);
  border: 1px solid var(--border-input);
  border-radius: var(--radius);
  padding: 10px 12px;
  color: var(--text-primary);
  font-size: 13px;
  font-family: var(--font-sans);
  outline: none;
  transition: border-color 0.2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: #3a3a3a; }

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #2a2a2a;
  font-size: 10px;
}
.divider::before, .divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.btn-outline-full {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  background: transparent;
  border: 1px solid var(--border-input);
  border-radius: var(--radius);
  padding: 10px 20px;
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: border-color 0.2s;
  font-family: var(--font-sans);
}
.btn-outline-full:hover { border-color: #3a3a3a; }

.form-note {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  min-height: 16px;
}
.form-note.error { color: #8b2a2a; }
.form-note.success { color: #2a7a2a; }

/* ---- FOOTER ---- */
.footer {
  padding: 32px 40px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-logo {
  font-family: var(--font-serif);
  font-size: 11px;
  letter-spacing: 3px;
  color: #333;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  font-size: 10px;
  color: #333;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--text-muted); }

.footer-copy {
  font-size: 10px;
  color: #2a2a2a;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 640px) {
  .nav { padding: 0 20px; }
  .section-features { padding: 60px 20px; }
  .section-pricing, .section-form { padding: 60px 20px; }
  .footer { padding: 24px 20px; flex-direction: column; text-align: center; }
  .hero-title { font-size: 28px; }
}
