/* ======================================
   GLOBAL DESIGN TOKENS
   ====================================== */

:root {
  --bg: #0b1220;
  --panel: rgba(255, 255, 255, 0.06);
  --panel-strong: rgba(255, 255, 255, 0.10);
  --text: rgba(255, 255, 255, 0.92);
  --muted: rgba(255, 255, 255, 0.70);
  --line: rgba(255, 255, 255, 0.14);
  --radius: 14px;
  --max: 1280px;
}

/* ======================================
   GLOBAL RESET + WIDTH LOCK
   ====================================== */

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

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

img,
video,
iframe,
canvas {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ======================================
   BODY
   ====================================== */

body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background:
    linear-gradient(rgba(11, 18, 32, 0.85), rgba(11, 18, 32, 0.85)),
    url("../images/background.jpg") center / cover no-repeat fixed;
}

/* ======================================
   CONTAINER
   ====================================== */

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

/* ======================================
   HEADER
   ====================================== */

.site-header {
  width: 100%;
  background: rgba(11, 18, 32, 0.85);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 0;
  flex-wrap: nowrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
  white-space: nowrap;
  min-width: 0;
}

.brand-logo {
  max-height: 72px;
  width: auto;
}

.brand-name {
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.1;
  white-space: nowrap;
}

.nav {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap; /* important: allows wrap when space is tight */
  justify-content: flex-end;
}

.nav a {
  text-decoration: none;
  color: var(--muted);
  white-space: nowrap;
  font-size: 0.98rem;
  padding: 10px 14px;
  border-radius: 999px; /* Ensures all nav items have the same rounded corners */
  border: 1px solid var(--line); /* Uniform border for all nav items */
  background: rgba(255, 255, 255, 0.06);
  transition: background 0.15s ease, border-color 0.15s ease;
}

.nav a:hover,
.nav a.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.12); /* Slightly lighter background on hover */
  border-color: rgba(255, 255, 255, 0.25); /* Consistent hover border */
}

/* Optional CTA styling if you want it consistent across pages */
.nav .nav-cta {
  background: rgba(255, 255, 255, 0.1); /* Ensure uniform background */
  border-radius: 999px; /* Make sure CTA has the same pill shape */
  padding: 10px 12px;
}

.nav .nav-cta:hover {
  background: rgba(255, 255, 255, 0.14); /* Consistent hover background */
}

/* ======================================
   FOOTER
   ====================================== */

.site-footer,
footer {
  width: 100%;
  border-top: 1px solid var(--line);
  background: rgba(11, 18, 32, 0.85);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 18px 0;
  text-align: center;
  width: 100%;
}

.footer-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  width: 100%;
}

.footer-nav a {
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
}

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

.footer-disclaimer {
  max-width: 720px;
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--muted);
}

.footer-disclaimer p {
  margin: 0.25rem 0;
}

.footer-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 0;
}

/* ======================================
   MOBILE HEADER FIX (keeps desktop look)
   ====================================== */

@media (max-width: 768px) {
  .header-inner {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
  }

  .brand {
    width: 100%;
    justify-content: center;
  }

  .brand-logo {
    max-height: 54px;
  }

  .brand-name {
    font-size: 1.35rem;
    white-space: nowrap;
  }

  .nav {
    width: 100%;
    justify-content: center;
    gap: 12px;
  }

  .nav a {
    font-size: 0.95rem;
  }

  .nav .nav-cta {
    padding: 9px 11px;
  }
}


/* RDL TOPNAV */
.rdl-topnav{
  position:sticky;top:0;z-index:50;
  background:rgba(12,12,14,.92);
  backdrop-filter:saturate(140%) blur(10px);
  border-bottom:1px solid rgba(255,255,255,.10);
}
.rdl-topnav-inner{
  max-width:1120px;margin:0 auto;
  display:flex;align-items:center;justify-content:space-between;
  gap:12px;padding:10px 16px;
}
.rdl-brand{
  font-weight:750;
  letter-spacing:.2px;
  text-decoration:none;
}
.rdl-navlinks{
  display:flex;gap:8px;flex-wrap:wrap;
}
.rdl-navlinks a{
  text-decoration:none;
  opacity:.92;
  padding:8px 10px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.08);
  background:rgba(255,255,255,.02);
}
.rdl-navlinks a:hover{
  opacity:1;
  border-color:rgba(255,255,255,.16);
  background:rgba(255,255,255,.04);
}
.rdl-navlinks a.active{
  opacity:1;
  border-color:rgba(255,255,255,.24);
  background:rgba(255,255,255,.06);
}
@media (max-width:520px){
  .rdl-topnav-inner{padding:10px 12px}
  .rdl-navlinks a{padding:7px 9px}
}



/* RDL UI KIT */
.rdl-container{max-width:1120px;margin:0 auto;padding:18px 16px 48px}
.muted{opacity:.82}

.rdl-panel{
  border:1px solid rgba(255,255,255,.10);
  border-radius:18px;
  padding:16px 16px;
  background:rgba(255,255,255,.03);
}

.rdl-grid{
  display:grid;
  grid-template-columns:repeat(12,1fr);
  gap:12px;
  margin-top:12px;
}

.rdl-card{
  grid-column:span 6;
  border:1px solid rgba(255,255,255,.10);
  border-radius:18px;
  padding:14px 14px;
  background:rgba(255,255,255,.02);
}

a.rdl-card{
  text-decoration:none;
  display:block;
}

.rdl-card:hover{
  border-color:rgba(255,255,255,.18);
  background:rgba(255,255,255,.03);
}

.rdl-card.disabled{
  opacity:.70;
}

@media (max-width:860px){
  .rdl-card{grid-column:span 12}
}

.rdl-kv{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin-top:10px;
}
.rdl-kv .k{display:block;font-size:12px;opacity:.72;margin-bottom:4px}
.rdl-kv .v{
  display:block;
  border:1px solid rgba(255,255,255,.10);
  border-radius:12px;
  padding:9px 10px;
  background:rgba(0,0,0,.16);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap
}

.rdl-field{display:flex;flex-direction:column;gap:6px}
.rdl-input{
  border:1px solid rgba(255,255,255,.12);
  border-radius:12px;
  padding:10px 12px;
  background:rgba(0,0,0,.18);
  outline:none;
}
.rdl-input:focus{border-color:rgba(255,255,255,.24)}
.rdl-btn{
  border:1px solid rgba(255,255,255,.14);
  border-radius:12px;
  padding:10px 12px;
  background:rgba(255,255,255,.06);
  cursor:pointer;
  color: var(--text);
  transition: background .15s ease, border-color .15s ease, opacity .15s ease;
}
.rdl-btn:hover{border-color:rgba(255,255,255,.22);background:rgba(255,255,255,.08)}
.rdl-btn:disabled{opacity:.55;cursor:not-allowed}

.rdl-btn--primary{
  background: rgba(93, 162, 255, 0.22);
  border-color: rgba(93, 162, 255, 0.48);
}
.rdl-btn--primary:hover{
  background: rgba(93, 162, 255, 0.30);
  border-color: rgba(93, 162, 255, 0.68);
}
.rdl-btn--secondary{
  background: rgba(255,255,255,.08);
}
.rdl-btn--ghost{
  background: transparent;
  border-color: rgba(255,255,255,.22);
}

.primary-btn,
.secondary-btn{
  border-radius:12px;
  padding:10px 12px;
  border:1px solid rgba(255,255,255,.14);
  color:var(--text);
}
.primary-btn{
  background: rgba(93, 162, 255, 0.22);
  border-color: rgba(93, 162, 255, 0.48);
}
.secondary-btn{
  background: rgba(255,255,255,.06);
}

.rdl-banner{
  border:1px solid rgba(255,255,255,.20);
  border-radius:12px;
  padding:10px 12px;
  margin:10px 0;
  background:rgba(255,255,255,.06);
}
.rdl-banner--error{
  border-color: rgba(235, 117, 117, 0.6);
  background: rgba(235, 117, 117, 0.14);
}
.rdl-banner--warn{
  border-color: rgba(255, 201, 102, 0.6);
  background: rgba(255, 201, 102, 0.14);
}
.rdl-banner--success{
  border-color: rgba(94, 214, 146, 0.55);
  background: rgba(94, 214, 146, 0.14);
}

.rdl-loading{
  display:flex;
  align-items:center;
  gap:10px;
  border:1px solid rgba(255,255,255,.14);
  border-radius:12px;
  padding:10px 12px;
  background:rgba(255,255,255,.04);
}
.rdl-spinner{
  width:14px;
  height:14px;
  border:2px solid rgba(255,255,255,.28);
  border-top-color: rgba(255,255,255,.92);
  border-radius:50%;
  animation: rdl-spin .7s linear infinite;
}
@keyframes rdl-spin{to{transform:rotate(360deg)}}

.rdl-empty-card{
  border:1px dashed rgba(255,255,255,.22);
  border-radius:12px;
  padding:12px;
  background:rgba(255,255,255,.03);
}
.rdl-empty-card h3{
  margin:0 0 6px;
  font-size:1rem;
}
.rdl-empty-card p{
  margin:0;
  opacity:.86;
}








/* RDL COLOR OVERRIDES START */
body a, body a:visited { color: rgba(255,255,255,.92); }
body a:hover { color: rgba(255,255,255,.96); }

.blog-page h1,.blog-page h2,.blog-page h3,
.dashboard-page h1,.dashboard-page h2,.dashboard-page h3,
.auth-page h1,.auth-page h2,.auth-page h3 { text-align: center; }

.blog-page h1,.blog-page h2,.blog-page h3,
.dashboard-page h1,.dashboard-page h2,.dashboard-page h3,
.auth-page h1,.auth-page h2,.auth-page h3 { color: rgba(255,255,255,.96); }
/* RDL COLOR OVERRIDES END */

/* RDL HEADER TIGHTEN v1 */
.container.header-inner{ min-width: 0; }
.brand{ display:flex; align-items:center; gap: 12px; }
.brand-logo{ width: 72px; height: 72px; object-fit: contain; display:block; }
.brand-name{ font-size: 22px; line-height: 1; white-space: nowrap; }

.nav{
  min-width: 0;
  display:flex;
  align-items:center;
  gap: 10px;
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}
.nav::-webkit-scrollbar{ height: 0; }
.nav a{ flex: 0 0 auto; }

@media (max-width: 520px){
  .brand-logo{ width: 60px; height: 60px; }
  .brand-name{ font-size: 18px; }
}

/* RDL LOGO SCALE v1 */
.brand-logo{
  width: 96px;
  height: 96px;
  object-fit: contain;
}
.brand-name{
  font-size: 24px;
  line-height: 1;
  white-space: nowrap;
}

/* keep nav from wrapping; allow horizontal scroll */
.nav{
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}
.nav::-webkit-scrollbar{ height: 0; }
.nav a{ flex: 0 0 auto; }

@media (max-width: 520px){
  .brand-logo{ width: 72px; height: 72px; }
  .brand-name{ font-size: 20px; }
}

/* RDL LOGO SCALE v2 */
.brand{ display:flex; align-items:center; gap: 14px; }
.brand-logo{ width: 120px; height: 120px; object-fit: contain; display:block; }
.brand-name{ font-size: 26px; line-height: 1; white-space: nowrap; }

/* keep nav from wrapping; allow horizontal scroll */
.nav{
  min-width: 0;
  display:flex;
  align-items:center;
  gap: 10px;
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}
.nav::-webkit-scrollbar{ height: 0; }
.nav a{ flex: 0 0 auto; }

@media (max-width: 520px){
  .brand-logo{ width: 88px; height: 88px; }
  .brand-name{ font-size: 20px; }
}

/* RDL LOGO SCALE v3 (final override) */
.brand{ display:flex; align-items:center; gap: 14px; }
.brand-logo{ width: 140px; height: 140px; object-fit: contain; display:block; }
.brand-name{ font-size: 28px; line-height: 1; white-space: nowrap; }

.nav{
  min-width: 0;
  display:flex;
  align-items:center;
  gap: 10px;
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}
.nav::-webkit-scrollbar{ height: 0; }
.nav a{ flex: 0 0 auto; }

@media (max-width: 520px){
  .brand-logo{ width: 96px; height: 96px; }
  .brand-name{ font-size: 20px; }
}

/* RDL NEW LOGO PNG v1 */
.brand-logo{
  height: 92px;
  width: auto;
  max-width: 560px;
  object-fit: contain;
  display:block;
  filter: drop-shadow(0 10px 18px rgba(0,0,0,0.35));
}

/* If the logo image contains the wordmark, hide the separate text label */
.brand-name{ display:none; }

@media (max-width: 520px){
  .brand-logo{ height: 70px; max-width: 340px; }
}

/* RDL HEADER LOGO BIG v1 */
.brand-logo{
  height: 96px;
  width: auto;
  max-width: 620px;
  object-fit: contain;
  display: block;
}

/* If the logo image includes the wordmark, hide the text label */
.brand-name{ display:none; }

@media (max-width: 520px){
  .brand-logo{ height: 74px; max-width: 360px; }
}

/* ======================================
   UI Design Pass: Spacing + Typography
   ====================================== */

:root {
  --rdl-shell-max: 1120px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 32px;
  --space-8: 40px;
  --type-h1: clamp(1.9rem, 2.6vw, 2.5rem);
  --type-h2: clamp(1.3rem, 1.8vw, 1.7rem);
  --type-h3: clamp(1.05rem, 1.25vw, 1.2rem);
  --type-body: 0.98rem;
  --type-body-sm: 0.9rem;
}

body {
  font-size: var(--type-body);
  line-height: 1.58;
}

.site-header .container,
.site-footer .container,
main.container,
.rdl-container,
.page {
  max-width: var(--rdl-shell-max);
}

.rdl-container {
  padding: var(--space-6) var(--space-4) var(--space-8);
}

.rdl-pagehead {
  margin: 0 0 var(--space-5);
}

.rdl-pagehead h1 {
  margin: 0 0 var(--space-2);
  font-size: var(--type-h1);
  line-height: 1.14;
  letter-spacing: -0.02em;
}

.rdl-pagehead p {
  margin: 0;
  font-size: var(--type-body-sm);
  line-height: 1.6;
}

.rdl-panel,
.rdl-card {
  padding: var(--space-5);
  border-radius: 16px;
}

.rdl-panel h2,
.rdl-card h2 {
  margin: 0 0 var(--space-3);
  font-size: var(--type-h2);
  line-height: 1.25;
}

.rdl-panel h3,
.rdl-card h3 {
  margin: var(--space-4) 0 var(--space-2);
  font-size: var(--type-h3);
  line-height: 1.32;
}

.rdl-form {
  display: grid;
  gap: var(--space-3);
}

.rdl-label {
  display: block;
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.84);
}

.rdl-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.rdl-input,
textarea.rdl-input,
select.rdl-input {
  min-height: 42px;
  font-size: var(--type-body-sm);
  line-height: 1.45;
}

.rdl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 10px 14px;
  font-size: 0.9rem;
  font-weight: 600;
}

.rdl-banner {
  margin: var(--space-3) 0;
  padding: 10px 12px;
  font-size: var(--type-body-sm);
  line-height: 1.45;
}

.rdl-loading {
  padding: 10px 12px;
  font-size: var(--type-body-sm);
}

.rdl-empty-card {
  padding: 12px 14px;
}

.rdl-empty-card h3 {
  font-size: 0.98rem;
}

.site-header .header-inner {
  gap: var(--space-4);
  padding: var(--space-4) 0;
}

.nav {
  justify-content: flex-end;
  gap: 10px;
}

.nav a {
  padding: 9px 14px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
}

.nav a.active,
.nav a[aria-current="page"] {
  color: rgba(255, 255, 255, 0.98);
  border-color: rgba(93, 162, 255, 0.68);
  background: rgba(93, 162, 255, 0.26);
  box-shadow: inset 0 0 0 1px rgba(93, 162, 255, 0.28);
}

.auth-page .rdl-pagehead h1,
.pricing-page .rdl-pagehead h1,
.dashboard-page .rdl-pagehead h1 {
  font-size: var(--type-h1);
}

.auth-page .rdl-pagehead p,
.pricing-page .rdl-pagehead p,
.dashboard-page .rdl-pagehead p,
.blog-page .blog-hero .sub,
.analyzer-page .analyzer-hero p {
  font-size: var(--type-body-sm);
  line-height: 1.6;
}

.blog-page .blog-hero h1,
.analyzer-page .analyzer-hero h1 {
  font-size: var(--type-h1);
  line-height: 1.15;
}

.auth-page .rdl-container,
.pricing-page .page,
.blog-page main.container {
  padding-top: var(--space-6);
  padding-bottom: var(--space-8);
}

.auth-page .auth-frame {
  padding: var(--space-5) !important;
  border-radius: 16px;
}

.pricing-page .pricing-grid {
  gap: var(--space-4);
  margin-top: var(--space-4);
}

.pricing-page .pricing-card {
  padding: var(--space-5);
  border-radius: 16px;
}

.pricing-page .pricing-card h2,
.pricing-page .pricing-card h3 {
  margin: 0 0 var(--space-2);
  font-size: var(--type-h3);
  line-height: 1.35;
}

.pricing-page .pricing-card .muted,
.auth-page .muted,
.blog-page .blog-summary,
.blog-page .blog-lead {
  font-size: var(--type-body-sm);
  line-height: 1.58;
}

.blog-page .blog-panel,
.blog-page .blog-card,
.blog-page .blog-post-shell {
  border-radius: 16px;
}

.blog-page .blog-panel {
  padding: var(--space-6);
}

.blog-page .blog-card {
  padding: var(--space-5);
}

.blog-page .blog-post-shell {
  padding: var(--space-6);
}
