/* ---- Theme Tokens ---- */
:root {
  --bg:#1a0f08;          /* deep blackened brown with orange undertone */
  --fg:#fff5e6;          /* warm creamy text */
  --muted:#e0b894;       /* muted tan/orange beige */
  --card:#26150b;        /* dark roasted brown-orange for cards */
  --accent:#ff6a00;      /* main vibrant orange */
  --accent-glow:#ffae42; /* glowing amber highlight */
  --acc1:#ff6a00;        /* bright flame orange */
  --acc2:#ff8c1a;        /* vivid pumpkin orange */
  --acc3:#ffc266;        /* golden honey */
  --edge:#803300;        /* burnt orange edge line */
  --shadow:0 0 16px rgba(255,106,0,.25); /* warm orange glow shadow */
  
  /* FlexNetJSX Theme Support */
  --bg-primary: var(--bg);
  --bg-secondary: var(--card);
  --text-primary: var(--fg);
  --text-secondary: var(--muted);
  --border-color: var(--edge);
  --accent-color: var(--accent);
  --success-color: #51cf66;
  --error-color: #ff6b6b;
  --warning-color: #ffd43b;
}

/* Theme support */
.theme-light {
  --bg-primary: #ffffff;
  --bg-secondary: #f8f9fa;
  --text-primary: #333333;
  --text-secondary: #666666;
  --border-color: #e1e5e9;
  --accent-color: #ff6a00;
  --success-color: #28a745;
  --error-color: #dc3545;
  --warning-color: #ffc107;
}

.theme-dark {
  --bg-primary: #1a0f08;
  --bg-secondary: #26150b;
  --text-primary: #fff5e6;
  --text-secondary: #e0b894;
  --border-color: #803300;
  --accent-color: #ff6a00;
  --accent-glow: #ffae42;
  --acc1: #ff6a00;
  --acc2: #ff8c1a;
  --acc3: #ffc266;
  --edge: #803300;
  --shadow: 0 0 16px rgba(255,106,0,.25);
  --success-color: #51cf66;
  --error-color: #ff6b6b;
  --warning-color: #ffd43b;
}

/* ---- Page Base ---- */
*{box-sizing:border-box}
html,body{
  margin:0; height:100%;
  background:var(--bg-primary);
  color:var(--text-primary);
  font:16px/1.5 system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,sans-serif;
  overflow-x:hidden;
}

/* Animated gradient glow backdrop */
body::before{
  content:"";
  position:fixed; inset:-20%;
  background:
    radial-gradient(800px 500px at 15% 10%, rgba(255,106,0,.25), transparent 55%),
    radial-gradient(700px 420px at 85% 15%, rgba(255,174,66,.22), transparent 60%),
    radial-gradient(900px 520px at 50% 120%, rgba(255,194,102,.18), transparent 65%);
  filter: blur(30px) saturate(120%);
  animation: drift 18s ease-in-out infinite alternate;
  z-index:-2;
}
@keyframes drift{
  0%{transform:translate3d(0,0,0) scale(1)}
  100%{transform:translate3d(2%, -1%, 0) scale(1.05)}
}

/* subtle scanlines for texture */
body::after{
  content:"";
  position:fixed; inset:0;
  background:
    linear-gradient(transparent 96%, rgba(255,255,255,.04) 96%) 0 0/100% 3px,
    linear-gradient(90deg, rgba(255,255,255,.03), transparent 30%, rgba(255,255,255,.03)) 0 0/6px 100%;
  pointer-events:none; z-index:-1; opacity:.35;
}

/* Layout container */
.container{ max-width:1100px; margin:0 auto; padding:2rem; }

/* ---- Type & Utilities ---- */
.center{text-align:center}
h1{
  margin:0 0 .75rem; font-size:2.1rem; letter-spacing:.4px; line-height:1.2;
  background: linear-gradient(90deg, var(--acc2), var(--acc1) 40%, var(--acc3));
  -webkit-background-clip:text; background-clip:text; color:transparent;
  filter: drop-shadow(0 0 8px rgba(255,174,66,.3));
}
.muted{ color:var(--text-secondary) }
.s{ font-size:.9rem }

/* Fancy link underline */
a{ color: var(--accent-color); text-decoration:none; position:relative }
a::after{
  content:""; position:absolute; left:0; bottom:-2px; height:2px; width:100%;
  background: linear-gradient(90deg, var(--acc1), var(--acc2), var(--acc3));
  transform-origin:left; transform:scaleX(.2); transition:transform .18s ease;
  border-radius:2px; opacity:.8;
}
a:hover::after{ transform:scaleX(1) }

/* ---- Cards (holo edge + slight lift) ---- */
.card{
  position:relative;
  background: var(--bg-secondary);
  padding:1rem; border-radius:16px;
  box-shadow: var(--shadow);
  border:1px solid var(--border-color);
  overflow:hidden;
}
.card::before{
  content:""; position:absolute; inset:-1px;
  border-radius:16px;
  background:
    conic-gradient(from 90deg,
      rgba(255,106,0,.0) 0deg,
      rgba(255,106,0,.35) 40deg,
      rgba(255,174,66,.35) 120deg,
      rgba(255,194,102,.28) 200deg,
      rgba(255,106,0,.0) 360deg);
  mask:
    linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: subtract;
  -webkit-mask-composite: subtract;
  pointer-events:none;
}

/* ---- FlexNetJSX App Layout ---- */

/* App layout */
.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg-primary);
}

/* Header */
.app-header {
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  position: relative;
  z-index: 10;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.app-title {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--text-primary);
  background: linear-gradient(90deg, var(--acc2), var(--acc1) 40%, var(--acc3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 8px rgba(255,174,66,.3));
}

.app-subtitle {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Navigation */
.app-navigation {
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 0.5rem 0;
  position: relative;
  z-index: 9;
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  gap: 1rem;
  align-items: center;
  overflow-x: auto;
}

.nav-link {
  padding: 0.5rem 1rem;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--text-primary);
  background-color: rgba(255, 106, 0, 0.1);
}

.nav-link.active {
  color: var(--accent-color);
  background-color: rgba(255, 106, 0, 0.15);
  font-weight: 500;
}

.nav-link.external {
  margin-left: auto;
  background-color: var(--accent-color);
  color: white;
}

.nav-link.external:hover {
  background-color: var(--acc2);
  color: white;
}

/* Main content */
.app-main {
  flex: 1;
  padding: 2rem 0;
}

/* Page layouts */
.page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Hero section */
.hero-section {
  text-align: center;
  padding: 3rem 0;
  margin-bottom: 3rem;
}

.hero-section h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  background: linear-gradient(90deg, var(--acc2), var(--acc1) 40%, var(--acc3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-section p {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

/* CTA section */
.cta-section {
  margin: 2rem 0;
}

.cta-text {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

/* Features section */
.features-section {
  margin: 3rem 0;
}

.features-section h3 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  text-align: center;
  color: var(--text-primary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.feature-card {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
}

.feature-card h4 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.feature-card p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---- Wallet Components ---- */

/* Wallet connect */
.wallet-connect {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.wallet-info {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  background: var(--bg-secondary);
  border-radius: 8px;
  border: 1px solid var(--border-color);
}

.wallet-address,
.wallet-balance {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.wallet-address .label,
.wallet-balance .label {
  font-weight: 500;
  color: var(--text-secondary);
}

.wallet-address .value,
.wallet-balance .value {
  font-family: monospace;
  color: var(--text-primary);
}

/* Wallet status */
.wallet-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
}

.wallet-status.disconnected {
  background-color: rgba(255, 107, 107, 0.1);
  color: var(--error-color);
}

.wallet-status.connected {
  background-color: rgba(81, 207, 102, 0.1);
  color: var(--success-color);
}

.status-indicator {
  font-size: 0.8rem;
}

/* KRN balance */
.krn-balance {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--bg-secondary);
  border-radius: 8px;
  border: 1px solid var(--border-color);
  font-size: 0.9rem;
}

.balance-label {
  color: var(--text-secondary);
  font-weight: 500;
}

.balance-value {
  color: var(--accent-color);
  font-weight: 600;
}

/* Wallet error */
.wallet-error {
  padding: 1rem;
  background-color: rgba(255, 107, 107, 0.1);
  border: 1px solid var(--error-color);
  border-radius: 8px;
  margin-bottom: 1rem;
}

.error-message {
  color: var(--error-color);
  margin-bottom: 0.5rem;
}

/* ---- Buttons ---- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--accent-color);
  color: white;
  min-height: 44px;
}

.btn:hover {
  background: var(--acc2);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 106, 0, 0.3);
}

.btn:active {
  transform: translateY(0);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn-primary {
  background: var(--accent-color);
  color: white;
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-secondary);
  border-color: var(--accent-color);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  min-height: 36px;
}

.btn-connecting {
  background: var(--warning-color);
  color: #333;
}

/* ---- Forms ---- */

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-primary);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 1rem;
  transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.1);
}

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

.form-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
}

/* Post form */
.post-form {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
}

/* ---- Content Feed ---- */

.content-feed {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.content-item {
  background: var(--bg-secondary);
  padding: 1.5rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease;
}

.content-item:hover {
  transform: translateY(-2px);
}

.content-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.content-author {
  font-weight: 500;
  color: var(--accent-color);
}

.content-date {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.content-text {
  line-height: 1.6;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.content-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.action-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.9rem;
}

.action-btn:hover {
  background: var(--bg-primary);
  color: var(--text-primary);
  border-color: var(--accent-color);
}

.action-btn.active {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
}

/* ---- Connect Prompt ---- */

.connect-prompt {
  text-align: center;
  padding: 3rem 1rem;
  max-width: 500px;
  margin: 0 auto;
}

.connect-prompt h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.connect-prompt p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.6;
}

/* ---- KRN Prompt ---- */

.krn-prompt {
  text-align: center;
  padding: 3rem 1rem;
  max-width: 500px;
  margin: 0 auto;
}

.krn-prompt h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.krn-prompt p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.6;
}

/* ---- Terms of Service Page ---- */

.terms-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
}

.terms-page .hero-section {
  text-align: center;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-color);
}

.terms-page .hero-section h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.terms-content {
  line-height: 1.6;
}

.terms-section {
  margin-bottom: 2.5rem;
}

.terms-section h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
}

.terms-section h4 {
  font-size: 1.2rem;
  margin: 1.5rem 0 0.5rem 0;
  color: var(--text-color);
}

.terms-section p {
  margin-bottom: 1rem;
  color: var(--text-color);
}

.terms-section ul {
  margin: 1rem 0;
  padding-left: 2rem;
}

.terms-section li {
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.terms-footer {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.terms-signature {
  font-weight: bold;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.terms-date {
  font-style: italic;
  color: var(--text-muted);
  margin-top: 1rem;
}

/* ---- Modal Styles ---- */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.modal-container {
  position: relative;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  max-width: 90vw;
  max-height: 90vh;
  width: 800px;
  display: flex;
  flex-direction: column;
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-secondary);
  border-radius: 12px 12px 0 0;
}

.modal-header h2 {
  margin: 0;
  color: var(--primary-color);
  font-size: 1.5rem;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 2rem;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: var(--border-color);
  color: var(--text-color);
}

.modal-content {
  flex: 1;
  overflow-y: auto;
  padding: 0;
}

.modal-content .terms-page {
  max-width: none;
  margin: 0;
  padding: 2rem;
  max-height: calc(90vh - 80px);
  overflow-y: auto;
}

.modal-content .terms-page .hero-section {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
}

.modal-content .terms-page .hero-section h2 {
  font-size: 2rem;
}

/* ---- Footer ---- */

.app-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 2rem 0;
  margin-top: auto;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s ease;
}

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

.footer-text {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ---- Modal ---- */

.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.modal-content {
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
  margin: 0;
  color: var(--text-primary);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: var(--bg-primary);
  color: var(--text-primary);
}

.modal-body {
  padding: 1.5rem;
}

/* ---- KRN Chart Section ---- */

.krn-chart-section {
  margin: 3rem 0;
  padding: 2rem;
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
}

.krn-chart-section h3 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  text-align: center;
  color: var(--text-primary);
}

.chart-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.chart-wrap {
  position: relative;
  width: 100%;
  height: 420px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  background:
    radial-gradient(1200px 420px at 50% -20%, rgba(255,106,0,.15), transparent 60%),
    radial-gradient(800px 300px at 95% 120%, rgba(255,174,66,.12), transparent 65%),
    var(--bg-primary);
}

.chart-wrap canvas {
  width: 100%;
  height: 100%;
  border: 0;
  background: transparent;
}

.token-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.token-details h4,
.top-holders h4 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.token-details p {
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}

.token-details strong {
  color: var(--text-primary);
}

.holders {
  list-style: none;
  padding: 0;
  margin: 0;
}

.holders li {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
  color: var(--text-secondary);
}

.holders li:last-child {
  border-bottom: 0;
}

.holders .addr {
  opacity: 0.8;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 70%;
}

.holders .amt {
  font-weight: 600;
  color: var(--text-primary);
}

/* ---- About Page ---- */

.about-page {
  max-width: 800px;
  margin: 0 auto;
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.about-section {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
}

.about-section h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.about-section p {
  line-height: 1.6;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.about-section ul {
  list-style: none;
  padding: 0;
}

.about-section li {
  padding: 0.5rem 0;
  color: var(--text-secondary);
  position: relative;
  padding-left: 1.5rem;
}

.about-section li::before {
  content: "•";
  color: var(--accent-color);
  position: absolute;
  left: 0;
  font-weight: bold;
}

/* ---- Manager Page ---- */

.manager-page {
  max-width: 800px;
  margin: 0 auto;
}

.manager-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.manager-info {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
}

.manager-info h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.manager-info p {
  line-height: 1.6;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.manager-info ul {
  list-style: none;
  padding: 0;
}

.manager-info li {
  padding: 0.5rem 0;
  color: var(--text-secondary);
  position: relative;
  padding-left: 1.5rem;
}

.manager-info li::before {
  content: "•";
  color: var(--accent-color);
  position: absolute;
  left: 0;
  font-weight: bold;
}

.chat-interface {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  text-align: center;
}

.chat-interface h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

/* ---- Entitlements Page ---- */

.entitlements-page {
  max-width: 1200px;
  margin: 0 auto;
}

.lore-section {
  margin: 2rem 0;
  padding: 2rem;
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  text-align: center;
}

.lore-content h3 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
  background: linear-gradient(90deg, var(--acc2), var(--acc1) 40%, var(--acc3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lore-content p {
  line-height: 1.6;
  margin-bottom: 1rem;
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.lore-signature {
  font-weight: bold;
  color: var(--accent-color) !important;
  font-size: 1.2rem !important;
  margin-top: 1.5rem !important;
}

/* Original Layout Styles */
.krn-layout {
  display: grid;
  gap: 1.25rem;
  margin: 2rem 0;
}

.form-col {
  display: flex;
  flex-direction: column;
}

.form-col .card {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
}

.feed-col {
  display: flex;
  flex-direction: column;
}

.feed {
  height: 100%;
  max-height: 70vh;
  overflow: auto;
  border-radius: 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
}

/* Feed Items */
.item {
  padding: 0.65rem 0.3rem;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.item:last-child {
  border-bottom: 0;
}

.time {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 0.25rem;
}

.msg {
  white-space: pre-wrap;
  word-break: break-word;
  margin: 0;
  font-family: inherit;
  background: none;
  border: none;
  color: var(--text-primary);
}

/* Feed Navigation */
.feed-nav {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin: 1rem 0;
}

.feed-link {
  display: inline-block;
  margin: 0.5rem 0.75rem;
  font-size: 0.9rem;
  color: var(--accent-color);
  text-decoration: none;
  opacity: 0.9;
  cursor: pointer;
}

.feed-link:hover {
  text-decoration: underline;
  opacity: 1;
}

.feed-link.hidden {
  display: none;
}

.feed-link.is-loading {
  pointer-events: none;
  opacity: 0.6;
}

/* Stars UI */
.stars {
  margin-top: 0.25rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.star-toggle {
  display: inline-block;
  text-decoration: none;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
}

.star-toggle[aria-pressed="true"] {
  filter: brightness(1.2);
  color: var(--accent-color);
}

.star-count {
  opacity: 0.85;
  font-variant-numeric: tabular-nums;
  color: var(--text-secondary);
}

/* Reveal Link */
.reveal-link {
  display: inline-block;
  margin-top: 0.3rem;
  font-size: 0.9rem;
  color: var(--accent-color);
  text-decoration: none;
  opacity: 0.9;
  cursor: pointer;
}

.reveal-link:hover {
  text-decoration: underline;
  opacity: 1;
}

.reveal-link.is-loading {
  pointer-events: none;
  opacity: 0.6;
}

/* Hidden elements */
.hidden {
  display: none !important;
}

.inline {
  display: inline;
}

/* Honeypot */
.hp {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Complaint Form */
.complaint-form {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.complaint-form .form-group {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.complaint-form textarea {
  flex-grow: 1;
  min-height: 10rem;
  max-height: 40vh;
  resize: vertical;
}

/* Responsive Layout */
@media (min-width: 700px) {
  .krn-layout {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "form feed";
    align-items: stretch;
    grid-auto-rows: minmax(0, auto);
  }
  
  .form-col {
    grid-area: form;
  }
  
  .feed-col {
    grid-area: feed;
  }
}

@media (min-width: 900px) {
  .krn-layout {
    align-items: stretch;
    grid-auto-rows: minmax(0, auto);
  }

  .form-col,
  .feed-col {
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  /* LEFT: form never scrolls; hide conic-gradient bleed */
  .form-col .card {
    flex: 1 1 auto;
    min-height: auto;
    overflow: hidden !important;   
  }
  
  .form-col textarea {
    flex-grow: 1;               
    min-height: 10rem;
    max-height: 40vh;         
  }

  /* RIGHT: feed is the only scroller */
  .feed-col .feed {
    flex: 1 1 auto;
    min-height: auto;
    max-height: 72vh;
    overflow: auto;        
  }
  
  /* Optional: avoid layout shift when feed gets a scrollbar */
  .feed-col .feed {
    scrollbar-gutter: stable both-edges;
  }
}

/* ---- Info Containers (Home Page) ---- */

.info-containers {
  display: grid;
  gap: 1.5rem;
  margin: 2rem 0;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.info-container {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-align: center;
}

.info-container:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-color: var(--accent-color);
}

.info-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

.info-container h3 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
  font-weight: 600;
}

.info-container p {
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

@media (min-width: 768px) {
  .info-containers {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 767px) {
  .info-containers {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .info-container {
    padding: 1rem;
  }
  
  .info-icon {
    font-size: 2.5rem;
  }
}

/* ---- Vote Page ---- */

.vote-page {
  max-width: 1200px;
  margin: 0 auto;
}

.vote-content {
  margin: 2rem 0;
}

.vote-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1rem;
}

.tab-btn {
  background: none;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  color: var(--text-secondary);
  font-weight: 500;
  transition: all 0.2s ease;
}

.tab-btn:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.tab-btn.active {
  background: var(--accent-color);
  color: var(--bg-primary);
  font-weight: 600;
}

.vote-items {
  margin-bottom: 2rem;
}

.vote-section h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.vote-actions {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  margin-top: 2rem;
}

.vote-actions h3 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.action-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.btn-danger {
  background: linear-gradient(135deg, #dc3545, #c82333);
  color: white;
}

.btn-warning {
  background: linear-gradient(135deg, #ffc107, #e0a800);
  color: #212529;
}

.btn-success {
  background: linear-gradient(135deg, #28a745, #1e7e34);
  color: white;
}

/* ---- Manager Page Chat Frame ---- */

.chat-container {
  margin-top: 2rem;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
}

.chat-frame {
  width: 100%;
  height: 600px;
  border: none;
  background: var(--bg-secondary);
}

/* ---- Mobile Styles ---- */

/* ===== Mobile polish ===== */
@media (max-width: 699px) {
  /* Keep stacked layout */
  .krn-layout {
    grid-template-columns: 1fr;
  }

  /* Smaller feed container on mobile */
  .feed {
    max-height: 48vh;
    overflow: auto;
  }

  /* Full-width, centered submit button on mobile */
  .form-col .card button[type="submit"],
  .form-col .card .btn {
    width: 100%;
  display: inline-block;
    text-align: center;
  }
}

/* ---- Responsive Design ---- */

@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
  
  .nav-content {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  
  .nav-link {
    padding: 0.5rem;
    font-size: 0.9rem;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-content {
    flex-direction: column;
    text-align: center;
  }
  
  .hero-section h2 {
    font-size: 2rem;
  }
  
  .app-title {
    font-size: 1.3rem;
  }
  
  .token-info {
    grid-template-columns: 1fr;
  }
  
  .chart-wrap {
    height: 300px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 1rem;
  }
  
  .page {
    padding: 0 0.5rem;
  }
  
  .hero-section {
    padding: 2rem 0;
  }
  
  .hero-section h2 {
    font-size: 1.8rem;
  }
  
  .btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
  }
}

/* Vote Page Styles */
.vote-page {
  padding: 2rem;
}

.vote-content {
  max-width: 1200px;
  margin: 0 auto;
}

.vote-header {
  text-align: center;
  margin-bottom: 2rem;
}

.vote-tabs {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.vote-tab {
  padding: 0.75rem 1.5rem;
  border: 2px solid var(--acc1);
  background: transparent;
  color: var(--acc1);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 600;
}

.vote-tab:hover {
  background: var(--acc1);
  color: var(--bg1);
}

.vote-tab.active {
  background: var(--acc1);
  color: var(--bg1);
}

.vote-items {
  display: grid;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.vote-item {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.vote-item:hover {
  border-color: var(--acc1);
  box-shadow: 0 4px 12px rgba(255, 165, 0, 0.1);
}

.vote-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.vote-author {
  font-weight: 600;
  color: var(--acc1);
  font-family: monospace;
}

.vote-strikes {
  background: var(--bg3);
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  color: var(--text2);
}

.vote-content {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.vote-stats {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

.vote-stat {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text2);
}

.vote-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.vote-action-btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.vote-action-btn.remove {
  background: #dc3545;
  color: white;
}

.vote-action-btn.remove:hover {
  background: #c82333;
}

.vote-action-btn.ban {
  background: #fd7e14;
  color: white;
}

.vote-action-btn.ban:hover {
  background: #e8690b;
}

.vote-action-btn.approve {
  background: #28a745;
  color: white;
}

.vote-action-btn.approve:hover {
  background: #218838;
}

.vote-info {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 2rem;
}

.vote-info h4 {
  margin-bottom: 1rem;
  color: var(--acc1);
}

.vote-info ul {
  list-style: none;
  padding: 0;
  margin-bottom: 1rem;
}

.vote-info li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
}

.vote-info li:last-child {
  border-bottom: none;
}

.vote-note {
  font-size: 0.875rem;
  color: var(--text2);
  font-style: italic;
}

/* Entitlements Page Styles */
.entitlements-page {
  padding: 2rem;
}

.krn-layout {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.complaint-form-section {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
}

.complaint-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-weight: 600;
  color: var(--text1);
}

.form-group textarea {
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg1);
  color: var(--text1);
  resize: vertical;
  min-height: 100px;
}

.submit-btn {
  padding: 0.75rem 1.5rem;
  background: var(--acc1);
  color: var(--bg1);
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  background: var(--acc2);
}

.feed-section {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
}

.feed-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.feed-item {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem;
  background: var(--bg1);
}

.feed-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.feed-author {
  font-weight: 600;
  color: var(--acc1);
}

.feed-time {
  font-size: 0.875rem;
  color: var(--text2);
}

.feed-content {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.feed-actions {
  display: flex;
  gap: 0.5rem;
}

.action-btn {
  padding: 0.25rem 0.75rem;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text1);
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.875rem;
  transition: all 0.3s ease;
}

.action-btn:hover {
  background: var(--bg3);
}

.action-btn.favorite:hover {
  border-color: #dc3545;
  color: #dc3545;
}

.action-btn.unfavorite:hover {
  border-color: #fd7e14;
  color: #fd7e14;
}

.action-btn.flag:hover {
  border-color: #ffc107;
  color: #ffc107;
}

.action-btn.favorite.active {
  background: #dc3545;
  color: white;
  border-color: #dc3545;
}

.action-btn.favorite.active:hover {
  background: #c82333;
  border-color: #c82333;
}

.reveal-btn {
  background: var(--acc1);
  color: var(--bg1);
  border: none;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 1rem;
  transition: all 0.3s ease;
}

.reveal-btn:hover {
  background: var(--acc2);
  transform: translateY(-1px);
}

/* Form states */
.error-message {
  background: #dc3545;
  color: white;
  padding: 0.75rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  font-size: 0.875rem;
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Feed states */
.loading {
  text-align: center;
  padding: 2rem;
  color: var(--text2);
  font-style: italic;
}

.error {
  text-align: center;
  padding: 2rem;
  color: #dc3545;
  background: rgba(220, 53, 69, 0.1);
  border-radius: 8px;
  margin: 1rem 0;
}

.no-complaints {
  text-align: center;
  padding: 2rem;
  color: var(--text2);
  font-style: italic;
  background: var(--bg2);
  border-radius: 8px;
  margin: 1rem 0;
}

/* Wallet overlay styles */
.page-with-overlay {
  position: relative;
}

.wallet-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.wallet-overlay-content {
  background: var(--bg1);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  max-width: 400px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.wallet-overlay-content h3 {
  margin-bottom: 1rem;
  color: var(--text1);
}

.wallet-overlay-content p {
  margin-bottom: 1.5rem;
  color: var(--text2);
  line-height: 1.5;
}

.wallet-overlay-content .btn {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
}

/* ===== BOT PAGE STYLES ===== */

.bot-page {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
}

.bot-header {
  text-align: center;
  margin-bottom: 2rem;
  padding: 2rem;
  background: var(--card);
  border: 1px solid var(--edge);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.bot-title {
  font-size: 2.5rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
  text-shadow: 0 0 20px rgba(255, 106, 0, 0.5);
}

.bot-subtitle {
  color: var(--muted);
  font-size: 1.1rem;
  margin: 0;
}

.chat-container {
  display: flex;
  flex-direction: column;
  height: 600px;
  background: var(--card);
  border: 1px solid var(--edge);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
  background: linear-gradient(135deg, var(--card) 0%, rgba(38, 21, 11, 0.8) 100%);
}

.chat-messages::-webkit-scrollbar {
  width: 8px;
}

.chat-messages::-webkit-scrollbar-track {
  background: rgba(128, 51, 0, 0.1);
  border-radius: 4px;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: var(--edge);
  border-radius: 4px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}

.message {
  margin-bottom: 1.5rem;
  max-width: 85%;
  animation: messageSlideIn 0.3s ease-out;
}

@keyframes messageSlideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.user-message {
  margin-left: auto;
  background: linear-gradient(135deg, var(--accent) 0%, var(--acc2) 100%);
  color: #fff;
  border-radius: 18px 18px 4px 18px;
  padding: 1rem 1.5rem;
  box-shadow: 0 4px 12px rgba(255, 106, 0, 0.3);
  position: relative;
}

.user-message::before {
  content: '';
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 8px solid var(--accent);
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
}

.assistant-message {
  margin-right: auto;
  background: linear-gradient(135deg, rgba(255, 106, 0, 0.1) 0%, rgba(255, 140, 26, 0.05) 100%);
  color: var(--fg);
  border: 1px solid rgba(255, 106, 0, 0.2);
  border-radius: 18px 18px 18px 4px;
  padding: 1rem 1.5rem;
  box-shadow: 0 4px 12px rgba(255, 106, 0, 0.1);
  position: relative;
}

.assistant-message::before {
  content: '';
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-right: 8px solid rgba(255, 106, 0, 0.2);
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
}

.message-content p {
  margin: 0;
  line-height: 1.6;
  word-wrap: break-word;
}

.typing-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 1.5rem;
  background: rgba(255, 106, 0, 0.05);
  border: 1px solid rgba(255, 106, 0, 0.1);
  border-radius: 18px 18px 18px 4px;
  max-width: 200px;
  margin-bottom: 1.5rem;
}

.typing-dots {
  display: flex;
  gap: 4px;
}

.typing-dots span {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  animation: typingBounce 1.4s infinite ease-in-out;
}

.typing-dots span:nth-child(1) { animation-delay: -0.32s; }
.typing-dots span:nth-child(2) { animation-delay: -0.16s; }
.typing-dots span:nth-child(3) { animation-delay: 0s; }

@keyframes typingBounce {
  0%, 80%, 100% {
    transform: scale(0.8);
    opacity: 0.5;
  }
  40% {
    transform: scale(1);
    opacity: 1;
  }
}

.typing-indicator p {
  margin: 0;
  color: var(--muted);
  font-style: italic;
  font-size: 0.9rem;
}

.message-input {
  display: flex;
  gap: 1rem;
  padding: 1.5rem;
  background: var(--card);
  border-top: 1px solid var(--edge);
  align-items: flex-end;
}

.user-input {
  flex: 1;
  min-height: 44px;
  max-height: 120px;
  padding: 0.75rem 1rem;
  background: var(--bg);
  border: 1px solid var(--edge);
  border-radius: 22px;
  color: var(--fg);
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.5;
  resize: none;
  outline: none;
  transition: all 0.3s ease;
}

.user-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.1);
}

.user-input:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.user-input::placeholder {
  color: var(--muted);
}

.send-button {
  padding: 0.75rem 1.5rem;
  background: linear-gradient(135deg, var(--accent) 0%, var(--acc2) 100%);
  color: #fff;
  border: none;
  border-radius: 22px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: 80px;
  box-shadow: 0 4px 12px rgba(255, 106, 0, 0.3);
}

.send-button:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--acc2) 0%, var(--acc3) 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 106, 0, 0.4);
}

.send-button:active:not(:disabled) {
  transform: translateY(0);
}

.send-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.clear-button {
  padding: 0.75rem 1.5rem;
  background: linear-gradient(135deg, var(--edge) 0%, rgba(128, 51, 0, 0.8) 100%);
  color: var(--fg);
  border: 1px solid var(--edge);
  border-radius: 22px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: 80px;
  box-shadow: 0 4px 12px rgba(128, 51, 0, 0.3);
}

.clear-button:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--accent) 0%, var(--acc2) 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 106, 0, 0.4);
}

.clear-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.bot-info {
  background: var(--card);
  border: 1px solid var(--edge);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow);
}

.bot-info h3 {
  color: var(--accent);
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.bot-features {
  list-style: none;
  padding: 0;
  margin-bottom: 1.5rem;
}

.bot-features li {
  padding: 0.5rem 0;
  color: var(--fg);
  position: relative;
  padding-left: 1.5rem;
}

.bot-features li::before {
  content: '💎';
  position: absolute;
  left: 0;
  top: 0.5rem;
  font-size: 0.9rem;
}

.bot-note {
  background: linear-gradient(135deg, rgba(255, 106, 0, 0.1) 0%, rgba(255, 140, 26, 0.05) 100%);
  border: 1px solid rgba(255, 106, 0, 0.2);
  border-radius: 8px;
  padding: 1rem;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
  margin: 0;
}

.api-error-notice {
  background: linear-gradient(135deg, rgba(255, 107, 107, 0.1) 0%, rgba(220, 53, 69, 0.05) 100%);
  border: 1px solid rgba(255, 107, 107, 0.3);
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  text-align: center;
}

.api-error-notice p {
  margin: 0;
  color: #ff6b6b;
  font-size: 0.9rem;
  font-weight: 500;
}

.bot-deployment-note {
  background: linear-gradient(135deg, rgba(255, 193, 7, 0.1) 0%, rgba(255, 193, 7, 0.05) 100%);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 8px;
  padding: 1rem;
  color: #ffd43b;
  font-size: 0.85rem;
  text-align: center;
  margin: 1rem 0 0 0;
}

/* Responsive design for bot page */
@media (max-width: 768px) {
  .bot-page {
    padding: 1rem;
  }
  
  .bot-title {
    font-size: 2rem;
  }
  
  .chat-container {
    height: 500px;
  }
  
  .message {
    max-width: 95%;
  }
  
  .message-input {
    padding: 1rem;
    gap: 0.5rem;
  }
  
  .send-button {
    padding: 0.75rem 1rem;
    min-width: 60px;
  }
}

@media (max-width: 480px) {
  .bot-header {
    padding: 1.5rem;
  }
  
  .bot-title {
    font-size: 1.8rem;
  }
  
  .chat-container {
    height: 400px;
  }
  
  .chat-messages {
    padding: 1rem;
  }
  
  .message {
    max-width: 100%;
    margin-bottom: 1rem;
  }
  
  .user-message,
  .assistant-message {
    padding: 0.75rem 1rem;
  }
}

/* Quick action cards */
.quick-card {
  padding: 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.quick-card:hover {
  background: var(--bg-tertiary);
  border-color: var(--acc1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 174, 66, 0.15);
}

.quick-card:active {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(255, 174, 66, 0.1);
}

.quick-card h4 {
  margin: 0 0 0.25rem 0;
  font-size: 0.9rem;
  color: var(--text-primary);
  font-weight: 600;
}

.quick-card p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.quick-card .icon {
  font-size: 1.5rem;
  color: var(--acc1);
  flex-shrink: 0;
}

/* Chat status */
.chat-status {
  text-align: center;
  margin-bottom: 1rem;
  padding: 0.5rem;
  background: var(--bg-secondary);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.chat-status p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Payment modal */
.payment-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(4px);
}

.payment-modal {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  max-width: 400px;
  width: 90%;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.payment-modal h3 {
  margin-bottom: 1rem;
  color: var(--acc1);
  font-size: 1.25rem;
}

.payment-modal p {
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.payment-modal button {
  padding: 0.75rem;
  border: none;
  border-radius: 8px;
  color: white;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.9rem;
}

.payment-modal button:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.payment-modal button:last-child {
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.payment-modal button:last-child:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

/* Responsive design for quick actions */
@media (max-width: 768px) {
  .quick-buttons {
    grid-template-columns: 1fr !important;
  }
  
  .payment-modal {
    margin: 1rem;
    padding: 1.5rem;
  }
}
