/* ==========================================================================
   Radkspace CSS | Premium Light Theme Indigo Redesign
   ========================================================================== */

:root {
  --bg-main: #f8fafc;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  
  --text-primary: #0f172a;    /* Dark slate for high contrast readability */
  --text-secondary: #475569;  /* Slate-600 for secondary text */
  --text-muted: #64748b;     /* Slate-500 for captions and icons */

  /* Light Theme Indigo Accents */
  --indigo-primary: #4f46e5;       /* Indigo-600 */
  --indigo-hover: #4338ca;         /* Indigo-700 */
  --indigo-light: #e0e7ff;         /* Indigo-100 */
  --indigo-extra-light: #f5f6ff;   /* Soft indigo tint */
  --indigo-text: #3730a3;          /* Indigo-800 for highlighted labels */
  
  --emerald-primary: #10b981;      /* Emerald-500 */
  --emerald-light: #f0fdf4;        /* Emerald-50 */
  --emerald-border: #bbf7d0;       /* Emerald-200 */
  --emerald-text: #15803d;         /* Emerald-700 */

  --border-color: #e2e8f0;         /* Slate-200 */
  --border-hover: #cbd5e1;         /* Slate-300 */

  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --transition-smooth: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.15s ease;
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.05), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
  --shadow-lg: 0 10px 25px -5px rgba(79, 70, 229, 0.04), 0 8px 10px -6px rgba(79, 70, 229, 0.04);
  --shadow-card-hover: 0 20px 25px -5px rgba(79, 70, 229, 0.08), 0 8px 10px -6px rgba(79, 70, 229, 0.08);
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Typography & Headers */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #0f172a;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

code {
  font-family: var(--font-mono);
  font-size: 13px;
  background: rgba(79, 70, 229, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--indigo-text);
  border: 1px solid rgba(79, 70, 229, 0.08);
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header Navigation */
.main-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  height: 64px;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.logo-icon-svg {
  color: var(--indigo-primary);
  vertical-align: middle;
}

.accent-text {
  color: var(--indigo-primary);
}

.header-contacts {
  display: flex;
  gap: 24px;
}

.header-contact-item {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.header-contact-item:hover {
  color: var(--indigo-primary);
}

/* Hero Section */
.hero-section {
  position: relative;
  padding: 140px 0 60px 0;
  text-align: center;
  background: radial-gradient(circle at top, #eef2ff 0%, var(--bg-main) 70%);
}

.hero-title {
  font-size: 42px;
  line-height: 1.15;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.03em;
  color: #0f172a;
}

.hero-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* Product Cards Section */
.products-section {
  padding: 40px 0;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

/* Card Styling: Matching the reference screenshot */
.product-grid-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
  height: 100%;
}

.product-grid-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
  border-color: var(--border-hover);
}

.card-content {
  padding: 32px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-meta-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.card-code {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.card-flag {
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 5px;
  background: var(--bg-main);
  transition: var(--transition-fast);
}

.card-flag:hover {
  color: var(--indigo-primary);
  border-color: var(--indigo-light);
  background: var(--indigo-extra-light);
}

.card-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}

.card-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 24px;
  min-height: 40px; /* Aligns description height */
}

/* Card Metric Display Block (Replacing Pricing in layout but keeping structure) */
.card-highlight-value {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.03em;
  margin-bottom: 2px;
  display: flex;
  align-items: baseline;
}

.card-highlight-sub {
  font-size: 13px;
  font-weight: 600;
  color: var(--indigo-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 24px;
}

/* Bullet list (Checklist) */
.card-bullet-list {
  list-style: none;
  margin-bottom: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
}

.card-bullet-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: #334155; /* Slate-700 */
  line-height: 1.45;
}

.checkmark-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.card-footer {
  margin-top: auto;
}

.btn-card-launch {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 8px;
  border: 1px solid var(--indigo-primary);
  background: var(--indigo-primary);
  color: #ffffff;
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition-fast);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.btn-card-launch:hover {
  background: var(--indigo-hover);
  border-color: var(--indigo-hover);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.15);
}

/* Registry Section */
.registry-section {
  padding: 40px 0 80px 0;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  background: var(--bg-secondary);
  box-shadow: var(--shadow-md);
}

.registry-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 14px;
}

.registry-table th, 
.registry-table td {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-color);
}

.registry-table th {
  background: #f8fafc;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.registry-table tr:last-child td {
  border-bottom: none;
}

.registry-table td {
  color: var(--text-primary);
}

.app-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  background: var(--indigo-primary);
}

.table-link {
  color: var(--indigo-primary);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
}

.table-link:hover {
  color: var(--indigo-hover);
  text-decoration: underline;
}

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid transparent;
}

.badge-sec {
  background: var(--indigo-extra-light);
  color: var(--indigo-text);
  border-color: var(--indigo-light);
}

.badge-success {
  background: var(--emerald-light);
  color: var(--emerald-text);
  border-color: var(--emerald-border);
}

/* Footer styling */
.main-footer {
  padding: 40px 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
}

.footer-bottom-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
}

.footer-link-highlight {
  color: var(--indigo-primary);
  font-weight: 500;
}

.footer-link-highlight:hover {
  color: var(--indigo-hover);
  text-decoration: underline;
}

/* Mobile Toggle Hamburger button */
.mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 20px;
  height: 14px;
  background: transparent;
  border: none;
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  transition: var(--transition-fast);
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
  .products-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .header-contacts {
    display: none;
  }
}

/* --- Single Page Desktop Mode --- */
@media (min-width: 992px) {
  body.single-page {
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    display: flex;
    flex-direction: column;
  }

  body.single-page .main-header {
    position: static;
    height: 56px;
    flex-shrink: 0;
  }

  body.single-page .header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
  }

  body.single-page .workspace-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 16px 0;
    overflow: hidden;
  }

  body.single-page .hero-section {
    padding: 10px 0;
    background: transparent;
    flex-shrink: 0;
  }

  body.single-page .hero-title {
    font-size: 28px;
    margin-bottom: 2px;
    text-align: center;
  }

  body.single-page .hero-subtitle {
    font-size: 13px;
    margin-bottom: 0;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.4;
  }

  body.single-page .products-section {
    padding: 0;
    background: transparent;
    flex: 1;
    min-height: 0;
    display: flex;
    align-items: center;
  }

  body.single-page .products-container {
    height: 100%;
    display: flex;
    align-items: stretch;
  }

  body.single-page .products-grid {
    margin-top: 0;
    gap: 20px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    width: 100%;
    height: 100%;
  }

  body.single-page .product-grid-card {
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
  }

  body.single-page .card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    box-sizing: border-box;
  }

  body.single-page .card-title {
    font-size: 20px;
    margin-bottom: 2px;
  }

  body.single-page .card-subtitle {
    font-size: 13px;
    margin-bottom: 12px;
    min-height: auto;
  }

  body.single-page .card-highlight-value {
    font-size: 26px;
    margin-bottom: 0;
  }

  body.single-page .card-highlight-sub {
    font-size: 12px;
    margin-bottom: 14px;
  }

  body.single-page .card-bullet-list {
    font-size: 13px;
    gap: 8px;
    margin-bottom: 16px;
  }

  body.single-page .btn-card-launch {
    padding: 10px 14px;
    font-size: 13px;
  }

  body.single-page .registry-section {
    padding: 0;
    background: transparent;
    flex-shrink: 0;
  }

  body.single-page .table-wrap {
    border-radius: 8px;
  }

  body.single-page .registry-table th, 
  body.single-page .registry-table td {
    padding: 10px 18px;
    font-size: 13px;
  }

  body.single-page .main-footer {
    padding: 0;
    height: 40px;
    flex-shrink: 0;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
  }

  body.single-page .footer-bottom-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    font-size: 12px;
  }
}

/* --- Mobile / Tablet Responsive Mode --- */
@media (max-width: 991.98px) {
  body.single-page {
    height: auto;
    width: 100%;
    overflow-y: auto;
    display: block;
    background-color: var(--bg-main);
  }

  body.single-page .main-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    z-index: 1000;
  }

  body.single-page .workspace-container {
    padding: 80px 0 24px 0;
    overflow: visible;
  }

  body.single-page .hero-section {
    padding: 20px 0;
    text-align: center;
  }

  body.single-page .hero-title {
    font-size: 28px;
    margin-bottom: 8px;
  }

  body.single-page .hero-subtitle {
    font-size: 14px;
    padding: 0 16px;
    line-height: 1.5;
  }

  body.single-page .products-section {
    padding: 24px 0;
  }

  body.single-page .products-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  body.single-page .product-grid-card {
    height: auto;
  }

  body.single-page .card-content {
    padding: 24px;
  }

  body.single-page .card-title {
    font-size: 22px;
    margin-bottom: 4px;
  }

  body.single-page .card-bullet-list {
    font-size: 14px;
    margin-bottom: 24px;
  }

  body.single-page .btn-card-launch {
    padding: 12px 16px;
    font-size: 14px;
  }

  body.single-page .registry-section {
    padding: 24px 0;
  }

  body.single-page .table-wrap {
    overflow-x: auto;
  }

  body.single-page .registry-table th, 
  body.single-page .registry-table td {
    padding: 12px 16px;
    font-size: 13px;
    white-space: nowrap;
  }

  body.single-page .main-footer {
    padding: 20px 0;
  }

  body.single-page .footer-bottom-container {
    flex-direction: column;
    gap: 8px;
    align-items: center;
    text-align: center;
  }
}
