:root {
  /* Colors */
  --color-bg: #050810;
  --color-surface: #0c101a;
  --color-surface-alt: #141a26;
  --color-text: #f5f7fb;
  --color-text-muted: #a0a6b8;
  --color-primary: #00b4ff;
  --color-primary-soft: rgba(0, 180, 255, 0.12);
  --color-primary-strong: #0091cc;
  --color-success: #35c98b;
  --color-warning: #ffb547;
  --color-danger: #ff4c6a;

  --gray-50: #f8fafc;
  --gray-100: #e2e8f0;
  --gray-200: #cbd5f5;
  --gray-300: #94a3b8;
  --gray-400: #64748b;
  --gray-500: #475569;
  --gray-600: #334155;
  --gray-700: #1e293b;
  --gray-800: #0f172a;
  --gray-900: #020617;

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  --text-xs: 0.75rem;   /* 12px */
  --text-sm: 0.875rem;  /* 14px */
  --text-base: 1rem;    /* 16px */
  --text-lg: 1.125rem;  /* 18px */
  --text-xl: 1.25rem;   /* 20px */
  --text-2xl: 1.5rem;   /* 24px */
  --text-3xl: 1.875rem; /* 30px */
  --text-4xl: 2.25rem;  /* 36px */

  --leading-tight: 1.2;
  --leading-normal: 1.6;

  /* Spacing scale (px) */
  --space-0: 0;
  --space-4: 0.25rem;  /* 4px */
  --space-8: 0.5rem;   /* 8px */
  --space-12: 0.75rem; /* 12px */
  --space-16: 1rem;    /* 16px */
  --space-20: 1.25rem; /* 20px */
  --space-24: 1.5rem;  /* 24px */
  --space-32: 2rem;    /* 32px */
  --space-40: 2.5rem;  /* 40px */
  --space-48: 3rem;    /* 48px */
  --space-64: 4rem;    /* 64px */
  --space-80: 5rem;    /* 80px */
  --space-96: 6rem;    /* 96px */

  /* Radius */
  --radius-xs: 3px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  /* Shadows */
  --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-hard: 0 18px 45px rgba(0, 0, 0, 0.55);
  --shadow-focus: 0 0 0 1px rgba(0, 180, 255, 0.6), 0 0 0 4px rgba(0, 180, 255, 0.28);

  /* Transitions */
  --transition-fast: 120ms ease-out;
  --transition-normal: 200ms ease-out;
  --transition-slow: 320ms ease-out;
}

/* ========================================
   Reset / Normalize
   ===================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  margin: 0;
}

h1, h2, h3, h4, h5, h6,
figure, blockquote, dl, dd,
ul, ol, p {
  margin: 0;
}

ul, ol {
  padding-left: 1.25rem;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

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

button {
  border: none;
  background: none;
  padding: 0;
}

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

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ========================================
   Base Styles
   ===================================== */
body {
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  background: radial-gradient(circle at top, #10182b 0, #050810 45%, #000000 100%);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
}

main {
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: var(--leading-tight);
  color: #ffffff;
}

h1 {
  font-size: clamp(2.25rem, 4vw, 3rem);
  margin-bottom: var(--space-16);
}

h2 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  margin-bottom: var(--space-12);
}

h3 {
  font-size: clamp(1.4rem, 2.4vw, 1.75rem);
  margin-bottom: var(--space-8);
}

h4 {
  font-size: var(--text-xl);
  margin-bottom: var(--space-8);
}

p {
  margin-bottom: var(--space-12);
  color: var(--color-text-muted);
}

p + p {
  margin-top: -0.35rem;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-normal), opacity var(--transition-fast);
}

a:hover {
  color: var(--color-primary-strong);
}

a:focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
  border-radius: var(--radius-xs);
}

strong, b {
  font-weight: 600;
}

small {
  font-size: var(--text-sm);
}

code, pre {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
}

hr {
  border: 0;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  margin: var(--space-24) 0;
}

/* ========================================
   Utilities
   ===================================== */

/* Layout containers */
.container {
  width: 100%;
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-16);
  padding-right: var(--space-16);
}

.section {
  padding-top: var(--space-64);
  padding-bottom: var(--space-64);
}

.section--tight {
  padding-top: var(--space-40);
  padding-bottom: var(--space-40);
}

.section__header {
  margin-bottom: var(--space-32);
}

/* Flex helpers */
.flex {
  display: flex;
}

.inline-flex {
  display: inline-flex;
}

.flex-row {
  flex-direction: row;
}

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

.flex-wrap {
  flex-wrap: wrap;
}

.items-center {
  align-items: center;
}

.items-start {
  align-items: flex-start;
}

.items-end {
  align-items: flex-end;
}

.justify-center {
  justify-content: center;
}

.justify-between {
  justify-content: space-between;
}

.gap-16 {
  gap: var(--space-16);
}

.gap-24 {
  gap: var(--space-24);
}

.gap-32 {
  gap: var(--space-32);
}

/* Grid helpers */
.grid {
  display: grid;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-24);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-24);
}

@media (max-width: 768px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Width helpers */
.w-full {
  width: 100%;
}

.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

/* Spacing helpers */
.mt-0 { margin-top: 0; }
.mt-8 { margin-top: var(--space-8); }
.mt-16 { margin-top: var(--space-16); }
.mt-24 { margin-top: var(--space-24); }
.mt-32 { margin-top: var(--space-32); }

.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: var(--space-8); }
.mb-16 { margin-bottom: var(--space-16); }
.mb-24 { margin-bottom: var(--space-24); }
.mb-32 { margin-bottom: var(--space-32); }

.pt-24 { padding-top: var(--space-24); }
.pb-24 { padding-bottom: var(--space-24); }

/* Visibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Status text colors */
.text-muted {
  color: var(--color-text-muted);
}

.text-success {
  color: var(--color-success);
}

.text-warning {
  color: var(--color-warning);
}

.text-danger {
  color: var(--color-danger);
}

/* ========================================
   Components
   ===================================== */

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  cursor: pointer;
  background: var(--color-primary);
  color: #020617;
  box-shadow: 0 16px 35px rgba(0, 180, 255, 0.28);
  transition:
    background-color var(--transition-normal),
    color var(--transition-normal),
    box-shadow var(--transition-normal),
    transform var(--transition-fast),
    border-color var(--transition-fast);
}

.btn--primary {
  background: linear-gradient(135deg, #00b4ff, #00e0ff);
}

.btn--outline {
  background: transparent;
  border-color: rgba(148, 163, 184, 0.6);
  color: var(--color-text);
  box-shadow: none;
}

.btn--ghost {
  background: rgba(15, 23, 42, 0.7);
  border-color: rgba(148, 163, 184, 0.2);
  color: var(--color-text);
}

.btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(0, 180, 255, 0.38);
}

.btn--outline:hover:not(:disabled) {
  border-color: var(--color-primary);
  background: rgba(15, 23, 42, 0.85);
}

.btn--ghost:hover:not(:disabled) {
  border-color: rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.95);
}

.btn:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.6);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}

.btn:focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
}

/* Forms */
.form-group {
  margin-bottom: var(--space-16);
}

label {
  display: block;
  margin-bottom: var(--space-8);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--gray-100);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="search"],
input[type="password"],
textarea,
select {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(148, 163, 184, 0.4);
  background-color: rgba(15, 23, 42, 0.9);
  color: var(--color-text);
  font-size: var(--text-sm);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}

input::placeholder,
textarea::placeholder {
  color: rgba(148, 163, 184, 0.7);
}

input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-focus);
  background-color: #020617;
}

textarea {
  min-height: 140px;
  resize: vertical;
}

input:disabled,
textarea:disabled,
select:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

/* Cards */
.card {
  position: relative;
  border-radius: var(--radius-lg);
  padding: var(--space-24);
  background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.18), transparent 55%),
              linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.98));
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(148, 163, 184, 0.28);
  overflow: hidden;
}

.card--subtle {
  background: rgba(15, 23, 42, 0.9);
  box-shadow: none;
}

.card__header {
  margin-bottom: var(--space-16);
}

.card__title {
  font-size: var(--text-lg);
  margin-bottom: var(--space-8);
}

.card__meta {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* Accent glow for tech feel */
.card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 80% -10%, rgba(0, 180, 255, 0.35), transparent 55%);
  opacity: 0.35;
  mix-blend-mode: screen;
}

/* Remove glow on subtle cards */
.card--subtle::after {
  display: none;
}

/* Badges / pills */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid rgba(148, 163, 184, 0.6);
  color: var(--gray-100);
  background: rgba(15, 23, 42, 0.8);
}

.badge--primary {
  border-color: rgba(0, 180, 255, 0.8);
  background: rgba(0, 180, 255, 0.1);
  color: var(--color-primary);
}

.badge--success {
  border-color: rgba(53, 201, 139, 0.8);
  background: rgba(53, 201, 139, 0.1);
  color: var(--color-success);
}

/* Focus-visible for interactive elements */
button:focus-visible,
[role="button"]:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
}

/* ========================================
   Helpers for PhoneFixx-specific sections
   ===================================== */

/* Timeline / steps for repair process */
.steps {
  position: relative;
  padding-left: 1.5rem;
}

.steps::before {
  content: "";
  position: absolute;
  top: 0.3rem;
  bottom: 0.3rem;
  left: 0.45rem;
  width: 2px;
  background: linear-gradient(to bottom, rgba(148, 163, 184, 0.3), rgba(0, 180, 255, 0.65));
}

.step {
  position: relative;
  padding-left: 1.4rem;
  margin-bottom: var(--space-16);
}

.step::before {
  content: "";
  position: absolute;
  top: 0.2rem;
  left: -0.1rem;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 999px;
  border: 2px solid rgba(15, 23, 42, 1);
  background: radial-gradient(circle, #00b4ff 0, #00b4ff 35%, #22c55e 100%);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.35);
}

/* Testimonials layout */
.testimonial {
  font-size: var(--text-sm);
}

.testimonial__quote {
  font-style: italic;
  color: var(--color-text);
}

.testimonial__author {
  margin-top: var(--space-12);
  font-weight: 500;
  color: var(--gray-100);
}

.testimonial__meta {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* Pricing highlights */
.price-tag {
  font-size: var(--text-xl);
  font-weight: 600;
  color: #ffffff;
}

.price-tag__suffix {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* Diagnostic emphasis */
.highlight-strip {
  border-radius: var(--radius-md);
  padding: var(--space-16);
  background: linear-gradient(90deg, rgba(0, 180, 255, 0.18), rgba(15, 23, 42, 0.94));
  border: 1px solid rgba(0, 180, 255, 0.35);
}

/* Simple responsive tweaks */
@media (max-width: 640px) {
  .section {
    padding-top: var(--space-48);
    padding-bottom: var(--space-48);
  }

  h1 {
    margin-bottom: var(--space-12);
  }

  .card {
    padding: var(--space-20);
  }
}
