:root {
  --bg: #07111a;
  --bg-soft: #0c1722;
  --panel: rgba(9, 20, 31, 0.85);
  --panel-border: rgba(119, 173, 255, 0.18);
  --text: #ebf3ff;
  --muted: #97abc2;
  --accent: #38d7c4;
  --accent-2: #5aa0ff;
  --accent-3: #f3c567;
  --danger: #ff7272;
  --success: #73f0a1;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Georgia, "Times New Roman", serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(56, 215, 196, 0.18), transparent 28%),
    radial-gradient(circle at right, rgba(90, 160, 255, 0.24), transparent 30%),
    linear-gradient(160deg, #050c14 0%, #0b1520 55%, #071018 100%);
}

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

button,
input,
select,
textarea {
  font: inherit;
}

.site-shell {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 64px;
}

.topbar,
.hero,
.section,
.glass,
.plan-card,
.panel-card,
.ticket-card,
.shift-card {
  backdrop-filter: blur(18px);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  box-shadow: var(--shadow);
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 18px 24px;
  border-radius: 999px;
  position: sticky;
  top: 16px;
  z-index: 10;
}

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

.brand-mark {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #021018;
  font-weight: 700;
}

.eyebrow,
.card-label {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  color: var(--accent);
  margin: 0 0 8px;
}

.topbar h1,
.hero h2,
.section h3,
.auth-panel h3 {
  margin: 0;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
}

.topnav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--muted);
}

.hero {
  margin-top: 28px;
  border-radius: 36px;
  padding: 36px;
  display: grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 28px;
}

.hero-kicker {
  margin: 0 0 12px;
  color: var(--accent-3);
}

.hero h2 {
  font-size: clamp(2.3rem, 5vw, 4.5rem);
  line-height: 0.98;
  max-width: 12ch;
}

.hero-text,
.section-heading p,
.muted,
.ticket-message small,
.meta-line {
  color: var(--muted);
}

.hero-actions,
.inline-actions,
.ticket-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  border: 0;
  cursor: pointer;
  padding: 12px 18px;
  border-radius: 999px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #04131c;
  font-weight: 700;
}

.secondary,
.ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.danger {
  background: rgba(255, 114, 114, 0.12);
  color: #ffd3d3;
  border: 1px solid rgba(255, 114, 114, 0.22);
}

.success {
  background: rgba(115, 240, 161, 0.13);
  color: #d7ffe5;
  border: 1px solid rgba(115, 240, 161, 0.22);
}

.payment-callout,
.info-panel,
.portal-preview,
.panel-card,
.ticket-card,
.shift-card {
  border-radius: var(--radius);
}

.payment-callout {
  margin-top: 24px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.05);
  display: grid;
  gap: 6px;
  width: fit-content;
}

.feature-stack,
.compact-list,
.stat-grid,
.plan-grid,
.panel-grid,
.ticket-grid,
.shift-grid {
  margin: 0;
  padding: 0;
  list-style: none;
}

.feature-stack li,
.compact-list li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.feature-stack li:last-child,
.compact-list li:last-child {
  border-bottom: 0;
}

.section {
  margin-top: 28px;
  padding: 28px;
  border-radius: 32px;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 24px;
}

.section-heading.compact {
  margin-bottom: 18px;
}

.plan-grid,
.panel-grid,
.ticket-grid,
.shift-grid,
.portal-grid,
.split-grid {
  display: grid;
  gap: 18px;
}

.plan-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.plan-card,
.panel-card,
.ticket-card,
.shift-card {
  border-radius: 24px;
  padding: 22px;
}

.plan-price {
  font-size: 1.8rem;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  margin: 10px 0 4px;
}

.plan-year {
  margin: 0 0 14px;
  color: var(--accent-3);
}

.split-grid,
.portal-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.glass {
  border-radius: 30px;
  padding: 28px;
}

.stack-form {
  display: grid;
  gap: 14px;
}

.stack-form label {
  display: grid;
  gap: 8px;
}

.stack-form input,
.stack-form select,
.stack-form textarea {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  border-radius: 16px;
  padding: 13px 14px;
}

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

.dashboard-shell {
  display: grid;
  gap: 24px;
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.dashboard-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.dashboard-tabs button.active {
  background: linear-gradient(135deg, rgba(56, 215, 196, 0.25), rgba(90, 160, 255, 0.25));
}

.dashboard-tabs a.button {
  text-decoration: none;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
}

.stat-card {
  padding: 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
}

.stat-card strong {
  display: block;
  font-size: 2rem;
  margin-top: 8px;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
}

.ticket-thread {
  margin-top: 14px;
  display: grid;
  gap: 12px;
}

.ticket-header,
.ticket-title-row,
.message-head,
.message-author {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.ticket-title-row {
  margin-top: 14px;
}

.ticket-author-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.ticket-message {
  padding: 14px;
  background: rgba(255, 255, 255, 0.045);
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.ticket-message-staff {
  background: linear-gradient(135deg, rgba(56, 215, 196, 0.08), rgba(90, 160, 255, 0.08));
}

.ticket-message-client {
  background: rgba(255, 255, 255, 0.045);
}

.ticket-message p {
  margin: 8px 0 0;
  white-space: pre-wrap;
}

.ticket-card-closed {
  opacity: 0.9;
}

.rank-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.08);
}

.rank-founder,
.rank-co-founder {
  background: rgba(243, 197, 103, 0.18);
  color: #ffe1a2;
}

.rank-admin {
  background: rgba(90, 160, 255, 0.18);
  color: #cfe0ff;
}

.rank-manager {
  background: rgba(255, 114, 114, 0.18);
  color: #ffd5d5;
}

.rank-support {
  background: rgba(56, 215, 196, 0.18);
  color: #cbfff8;
}

.rank-security {
  background: rgba(255, 141, 168, 0.18);
  color: #ffd0dc;
}

.rank-client {
  background: rgba(255, 255, 255, 0.08);
  color: #edf3ff;
}

.typing-bubble {
  width: fit-content;
  display: flex;
  align-items: center;
  gap: 6px;
}

.typing-bubble span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.8);
  animation: typingPulse 1s infinite ease-in-out;
}

.typing-bubble span:nth-child(2) {
  animation-delay: 0.15s;
}

.typing-bubble span:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes typingPulse {
  0%, 80%, 100% {
    opacity: 0.35;
    transform: translateY(0);
  }

  40% {
    opacity: 1;
    transform: translateY(-3px);
  }
}

.attachment-list {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.attachment-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
}

.attachment-card img {
  width: min(100%, 320px);
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.empty-state {
  padding: 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.8rem;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
}

.hidden {
  display: none !important;
}

.alert {
  padding: 12px 14px;
  border-radius: 16px;
  margin-bottom: 14px;
}

.alert.error {
  background: rgba(255, 114, 114, 0.11);
  color: #ffd0d0;
}

.alert.success {
  background: rgba(115, 240, 161, 0.11);
  color: #d9ffdf;
}

@media (max-width: 920px) {
  .topbar,
  .hero,
  .split-grid,
  .portal-grid,
  .dashboard-header {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .topbar {
    border-radius: 28px;
  }

  .hero {
    padding: 24px;
  }

  .hero h2 {
    max-width: 100%;
  }
}
