:root {
  --bg-left: #0f172a;
  --bg-right: #f8fafc;
  --text-primary: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --accent: #6366f1;
  --accent-hover: #4f46e5;
  --radius: 8px;
  --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg-right: #0b0f19;
    --text-primary: #f8fafc;
    --text-muted: #94a3b8;
    --border-color: #1e293b;
  }
}

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

body {
  font-family: var(--font-family);
  background-color: var(--bg-right);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.5;
  overflow-x: hidden;
}

/* Responsive Split Layout (~38% Left Art, ~62% Right Main) */
.split-layout {
  display: flex;
  min-height: 100vh;
  width: 100vw;
}

/* LEFT PANEL: Background Sky Art Showcase */
.split-art {
  flex: 0 0 38%;
  max-width: 38%;
  background-size: cover;
  background-position: center;
  position: relative;
  min-height: 100vh;
}

.art-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.25) 0%, rgba(15, 23, 42, 0.75) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 3.5rem 3rem;
}

.hero-ad h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.25;
  margin-bottom: 1rem;
  letter-spacing: -0.5px;
}

.hero-ad p {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.6;
  max-width: 440px;
}

/* RIGHT PANEL: Clean & Minimal Interface */
.split-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 3rem 4rem;
  background-color: var(--bg-right);
  min-height: 100vh;
}

/* Top Header Logo on Clean Panel */
.main-header {
  margin-bottom: 2rem;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  width: fit-content;
}

.brand-logo-badge {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background-color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.25);
  flex-shrink: 0;
}

.brand-logo {
  display: block;
}

.brand-name {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.5px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

.brand-cloud {
  font-size: 0.65rem;
  background: var(--accent);
  color: #ffffff;
  padding: 2px 7px;
  border-radius: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  line-height: 1;
}

.main-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
}

/* Auth Card */
.auth-card {
  width: 100%;
}

.auth-header {
  margin-bottom: 2rem;
}

.auth-header h2 {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.auth-header p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.oauth-stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 1.75rem;
}

.btn {
  width: 100%;
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  transition: all 0.15s ease-in-out;
  border: 1px solid transparent;
}

.btn-github {
  background-color: #0f172a;
  color: #ffffff;
}

.btn-github:hover {
  background-color: #1e293b;
}

.btn-google {
  background-color: #ffffff;
  color: #0f172a;
  border-color: var(--border-color);
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.btn-google:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
}

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

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

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

.btn-secondary:hover {
  background-color: rgba(0,0,0,0.03);
}

.auth-privacy-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
}

/* Dashboard Component */
.dashboard-card {
  width: 100%;
}

.dash-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.dash-title {
  font-size: 1.5rem;
  font-weight: 700;
}

.dash-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.sites-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.site-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  background-color: var(--bg-right);
}

.site-domain-name {
  font-weight: 600;
  font-size: 1rem;
}

.site-id-code {
  font-family: monospace;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

/* Footer */
.main-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);

}

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

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
}

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

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.modal-box {
  background-color: var(--bg-right);
  width: 100%;
  max-width: 480px;
  border-radius: calc(var(--radius) * 1.5);
  padding: 2rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--border-color);
}

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

.btn-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
}

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

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 0.4rem;
}

.form-group input {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  background-color: transparent;
  color: var(--text-primary);
  font-size: 0.9rem;
}

.form-section {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin: 1.5rem 0 1rem 0;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.hidden {
  display: none !important;
}

@media (max-width: 900px) {
  .split-layout {
    flex-direction: column;
  }
  .split-art {
    flex: none;
    max-width: 100%;
    min-height: 280px;
  }
  .split-main {
    padding: 2rem 1.5rem;
  }
}
