/* ========================================================================
   Base Stylesheet (base.css)
   Clean, modern, fresh, professional, trustworthy, eco-friendly
   ======================================================================== */

/* ========================================================================
   1. CSS Custom Properties (Variables)
   ======================================================================== */

:root {
  /* Color Palette - Soft whites, cool blues, gentle greys, eco accent */
  --color-background: #f6f8fb; /* main page background */
  --color-surface: #ffffff;    /* cards, panels */
  --color-text: #1f2933;       /* primary text */
  --color-text-muted: #6b7280; /* secondary text */

  --color-primary: #2563eb;          /* cool, trustworthy blue */
  --color-primary-soft: #e0edff;     /* soft blue tint for subtle accents */
  --color-primary-strong: #1d4ed8;   /* darker primary for hover/focus */

  --color-success: #22c55e;          /* eco / success green */
  --color-warning: #f59e0b;          /* gentle amber */
  --color-danger: #ef4444;           /* clear but not harsh red */

  /* Neutral grays for borders, backgrounds, text */
  --color-gray-50: #f9fafb;
  --color-gray-100: #f3f4f6;
  --color-gray-200: #e5e7eb;
  --color-gray-300: #d1d5db;
  --color-gray-400: #9ca3af;
  --color-gray-500: #6b7280;
  --color-gray-600: #4b5563;
  --color-gray-700: #374151;
  --color-gray-800: #1f2933;
  --color-gray-900: #111827;

  --color-border-subtle: var(--color-gray-200);
  --color-border-strong: var(--color-gray-300);

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji",
    "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --font-serif: "Georgia", "Times New Roman", serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", "Courier New", monospace;

  /* Font sizes (desktop base 16px) */
  --font-size-xs: 0.75rem;  /* 12px */
  --font-size-sm: 0.875rem; /* 14px */
  --font-size-md: 1rem;     /* 16px */
  --font-size-lg: 1.125rem; /* 18px */
  --font-size-xl: 1.25rem;  /* 20px */
  --font-size-2xl: 1.5rem;  /* 24px */
  --font-size-3xl: 1.875rem;/* 30px */
  --font-size-4xl: 2.25rem; /* 36px */

  /* Line heights */
  --line-height-tight: 1.2;
  --line-height-snug: 1.35;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.7;

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

  /* Radii (soft, approachable, modern) */
  --radius-sm: 0.25rem; /* 4px */
  --radius-md: 0.5rem;  /* 8px */
  --radius-lg: 0.75rem; /* 12px */
  --radius-xl: 1rem;    /* 16px */
  --radius-pill: 9999px;

  /* Shadows (subtle, clean) */
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08),
    0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.10);
  --shadow-lg: 0 16px 40px rgba(15, 23, 42, 0.14);

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

  /* Layout */
  --container-max-width: 1120px;

  /* Focus outline (high contrast, brand-aligned) */
  --focus-ring-color: rgba(37, 99, 235, 0.6);
  --focus-ring-offset: 3px;
  --focus-ring-width: 2px;
}

/* ========================================================================
   2. Reset & Normalize
   ======================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

ul[role="list"],
ol[role="list"] {
  list-style: none;
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
}

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

img {
  height: auto;
}

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

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

textarea {
  resize: vertical;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Improve default focus visibility for keyboard users */
:focus-visible {
  outline: var(--focus-ring-width) solid var(--focus-ring-color);
  outline-offset: var(--focus-ring-offset);
}

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

/* ========================================================================
   3. Base Typography & Elements
   ======================================================================== */

body {
  font-family: var(--font-sans);
  font-size: var(--font-size-md);
  line-height: var(--line-height-relaxed);
  background-color: var(--color-background);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main {
  display: block;
}

/* Headings: modern, structured scale */

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

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

h2 {
  font-size: clamp(1.5rem, 2.4vw, var(--font-size-3xl));
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

h3 {
  font-size: var(--font-size-2xl);
  margin-top: var(--space-6);
  margin-bottom: var(--space-3);
}

h4 {
  font-size: var(--font-size-xl);
  margin-top: var(--space-4);
  margin-bottom: var(--space-2);
}

h5 {
  font-size: var(--font-size-lg);
  margin-top: var(--space-3);
  margin-bottom: var(--space-2);
}

h6 {
  font-size: var(--font-size-sm);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-top: var(--space-3);
  margin-bottom: var(--space-2);
}

p {
  margin-top: 0;
  margin-bottom: var(--space-4);
}

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

strong {
  font-weight: 600;
}

/* Links - clean, brand-aligned, no default underline */

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

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

a:focus-visible {
  outline: var(--focus-ring-width) solid var(--focus-ring-color);
  outline-offset: 3px;
}

/* Lists */

ul,
ol {
  padding-left: 1.25rem;
  margin-top: 0;
  margin-bottom: var(--space-4);
}

li + li {
  margin-top: 0.25em;
}

/* Horizontal rule for subtle section separation */

hr {
  border: 0;
  border-top: 1px solid var(--color-border-subtle);
  margin: var(--space-8) 0;
}

/* Blockquotes for testimonials / emphasis */

blockquote {
  margin: var(--space-6) 0;
  padding-left: var(--space-4);
  border-left: 3px solid var(--color-primary-soft);
  color: var(--color-text-muted);
  font-style: italic;
}

/* ========================================================================
   4. Layout Utilities
   ======================================================================== */

/* Centered content container */

.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

@media (min-width: 768px) {
  .container {
    padding-inline: var(--space-6);
  }
}

/* Section spacing helpers (for main vertical rhythm) */

.section {
  padding-block: var(--space-10);
}

.section--tight {
  padding-block: var(--space-6);
}

.section--wide {
  padding-block: var(--space-16);
}

/* Flexbox helpers */

.flex {
  display: flex;
}

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

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

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

.gap-xs {
  gap: var(--space-2);
}

.gap-sm {
  gap: var(--space-3);
}

.gap-md {
  gap: var(--space-4);
}

.gap-lg {
  gap: var(--space-6);
}

.gap-xl {
  gap: var(--space-8);
}

/* Simple grid helper for responsive content blocks */

.grid {
  display: grid;
  gap: var(--space-6);
}

.grid-2 {
  display: grid;
  gap: var(--space-6);
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

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

@media (min-width: 1024px) {
  .grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Alignment & text utilities */

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

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

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

/* Spacing utilities (commonly needed) */

.mt-0 { margin-top: 0 !important; }
.mt-xs { margin-top: var(--space-2) !important; }
.mt-sm { margin-top: var(--space-3) !important; }
.mt-md { margin-top: var(--space-4) !important; }
.mt-lg { margin-top: var(--space-6) !important; }
.mt-xl { margin-top: var(--space-8) !important; }

.mb-0 { margin-bottom: 0 !important; }
.mb-xs { margin-bottom: var(--space-2) !important; }
.mb-sm { margin-bottom: var(--space-3) !important; }
.mb-md { margin-bottom: var(--space-4) !important; }
.mb-lg { margin-bottom: var(--space-6) !important; }
.mb-xl { margin-bottom: var(--space-8) !important; }

/* Visually hidden but accessible (screen reader only) */

.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;
}

/* ========================================================================
   5. Form Elements & Buttons
   ======================================================================== */

/* Buttons: primary for actions (e.g., booking, support, eco options) */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding-inline: var(--space-4);
  padding-block: 0.65rem;
  border-radius: var(--radius-pill);
  font-weight: 500;
  font-size: var(--font-size-sm);
  line-height: 1.2;
  cursor: pointer;
  border: 1px solid transparent;
  transition:
    background-color var(--transition-normal),
    color var(--transition-normal),
    border-color var(--transition-normal),
    box-shadow var(--transition-fast),
    transform var(--transition-fast);
  text-decoration: none;
}

.btn-primary {
  background-color: var(--color-primary);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background-color: var(--color-primary-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
  color: #ffffff;
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: var(--shadow-xs);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-primary);
  border-color: rgba(37, 99, 235, 0.45);
  background-image: linear-gradient(
    to right,
    rgba(37, 99, 235, 0.04),
    rgba(37, 99, 235, 0.02)
  );
}

.btn-outline:hover {
  background-color: rgba(37, 99, 235, 0.06);
}

.btn-ghost {
  background-color: transparent;
  color: var(--color-text);
}

.btn-ghost:hover {
  background-color: rgba(15, 23, 42, 0.04);
}

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

.btn-success:hover {
  filter: brightness(0.95);
}

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

.btn:focus-visible {
  outline: var(--focus-ring-width) solid var(--focus-ring-color);
  outline-offset: 3px;
}

/* Inputs: clean, consistent fields for forms (contact, pickup/drop-off) */

.input,
select,
textarea {
  width: 100%;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border-strong);
  background-color: var(--color-surface);
  font-size: var(--font-size-sm);
  line-height: var(--line-height-normal);
  transition:
    border-color var(--transition-normal),
    box-shadow var(--transition-normal),
    background-color var(--transition-fast);
}

.input::placeholder,
textarea::placeholder {
  color: var(--color-gray-400);
}

.input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.25);
}

.input[disabled],
select[disabled],
textarea[disabled] {
  background-color: var(--color-gray-50);
  color: var(--color-gray-400);
  cursor: not-allowed;
}

label {
  display: inline-block;
  margin-bottom: 0.35rem;
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-text);
}

.form-field {
  margin-bottom: var(--space-4);
}

.form-helper-text {
  margin-top: 0.25rem;
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
}

.form-error-text {
  margin-top: 0.25rem;
  font-size: var(--font-size-xs);
  color: var(--color-danger);
}

/* ========================================================================
   6. Components (Cards, Badges, etc.)
   ======================================================================== */

/* Card component - for services, eco-process, testimonials, etc. */

.card {
  background-color: var(--color-surface);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.18);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
}

.card--soft {
  background: linear-gradient(
      135deg,
      rgba(224, 237, 255, 0.6),
      rgba(240, 249, 255, 0.35)
    ),
    #ffffff;
}

.card-header {
  margin-bottom: var(--space-4);
}

.card-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

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

.card-body {
  font-size: var(--font-size-sm);
}

/* Badge / pill for eco-friendly, premium, etc. */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: var(--font-size-xs);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-eco {
  background-color: rgba(34, 197, 94, 0.08);
  color: #15803d;
}

.badge-info {
  background-color: rgba(37, 99, 235, 0.08);
  color: #1d4ed8;
}

/* Testimonial styling (aligning with trust & quality) */

.testimonial {
  background-color: #ffffff;
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: var(--shadow-xs);
}

.testimonial-quote {
  font-size: var(--font-size-md);
  color: var(--color-text);
}

.testimonial-author {
  margin-top: var(--space-4);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-text);
}

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

/* Subtle info banner for pickup & drop-off information */

.info-banner {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: center;
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  background: linear-gradient(
      120deg,
      rgba(224, 237, 255, 0.8),
      rgba(240, 249, 255, 0.9)
    );
  border: 1px solid rgba(191, 219, 254, 0.9);
}

.info-banner-title {
  font-weight: 600;
}

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

/* ========================================================================
   7. Media & Imagery
   ======================================================================== */

/* Subtle, clean styling for high-quality garments/facility photos */

.image-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  background-color: #ffffff;
}

.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Light overlay for media when needed (e.g., eco-process visuals) */

.image-overlay-soft {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.image-overlay-soft::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at top,
    rgba(224, 242, 254, 0.55),
    transparent 65%
  );
  pointer-events: none;
}

/* ========================================================================
   8. Helper States
   ======================================================================== */

.is-muted {
  opacity: 0.6;
}

.is-hidden {
  display: none !important;
}

.is-full-width {
  width: 100%;
}

/* ========================================================================
   End of base.css
   ======================================================================== */
