/* master.css — Modern, MDN-style, mobile-first */

/* 1) Reset & Box-Sizing */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  line-height: 1.5;                   /* Improve text legibility */
  -webkit-text-size-adjust: 100%;     /* Prevent font inflation on mobile */
}

body {
  margin: 0;
  font-family: var(--font-family);
  font-size: 1rem;                    /* 16px base */
  line-height: var(--line-height);
  color: var(--color-text);
  background-color: var(--color-background);
}

/* 2. Root custom properties */
:root {
  /* Typography */
  --font-family: system-ui, -apple-system, BlinkMacSystemFont,
                 "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --line-height: 1.5;

  /* Base font scaling */
  --scale-ratio: 1.2;

  /* Colors */
  --color-primary: #007bff;
  --color-secondary: #6c757d;
  --color-success: #28a745;
  --color-danger: #dc3545;
  --color-warning: #ffc107;
  --color-info: #17a2b8;
  --color-light: #f8f9fa;
  --color-dark: #343a40;
  --color-text: #141413;
  --color-background: #f0eee6;

  /* Spacing */
  --spacing-unit: 1rem;               /* 16px */
}

/* 3. Base Typography & Layout */
h1, h2, h3, h4, h5, h6 {
  margin-top: var(--spacing-unit);
  margin-bottom: calc(var(--spacing-unit) / 2);
  line-height: 1.2;
  font-weight: 600;
}

p {
  margin-bottom: var(--spacing-unit);
}

section {
  margin-top: 3rem;
  margin-bottom: 1rem;
  text-align: center;
}

.container {
  width: 100%;
  max-width: 68.75rem; /* 1100px */
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--spacing-unit);
  padding-right: var(--spacing-unit);
}

/* 4. Media & Images */
img, picture, video, canvas, svg, iframe {
  display: block;
  max-width: 100%;
  height: auto;
}

/* 5. Links & Buttons */
a {
  color: var(--color-primary);
  text-decoration: none;
}
a:hover,
a:focus {
  text-decoration: underline;
}

/* Button Base */
.btn {
  display: inline-block;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  padding: 0.5rem 1rem;
  border: 1px solid transparent;
  border-radius: 0.25rem;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

/* Primary Variant */
.btn-primary {
  background-color: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}
.btn-primary:hover,
.btn-primary:focus {
  background-color: #0056b3;          /* Manually chosen darker shade */
  border-color: #004085;
}

/* 6. Utility Classes */
/* Text */
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-left  { text-align: left !important; }

/* Margin */
.m-0  { margin: 0 !important; }
.mt-1 { margin-top: var(--spacing-unit) !important; }
.mb-1 { margin-bottom: var(--spacing-unit) !important; }
.ml-1 { margin-left: var(--spacing-unit) !important; }
.mr-1 { margin-right: var(--spacing-unit) !important; }

/* Padding */
.p-0  { padding: 0 !important; }
.pt-1 { padding-top: var(--spacing-unit) !important; }
.pb-1 { padding-bottom: var(--spacing-unit) !important; }
.pl-1 { padding-left: var(--spacing-unit) !important; }
.pr-1 { padding-right: var(--spacing-unit) !important; }

/* Flex & Grid */
.flex { display: flex !important; }
.grid { display: grid !important; gap: var(--spacing-unit) !important; }
.flex-center { justify-content: center; align-items: center; }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }

/* Responsive helpers */
@media (min-width: 48rem) {
  .grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
}

/*  Form layout */
.form-group {
  display: flex;
  flex-direction: column;       /* stack input + button */
  gap: var(--spacing-unit);     /* vertical gap */
  max-width: 100%;              /* mobile: full width */
  margin: var(--spacing-unit) auto 0; /* center + top margin */
}

/* Responsive trim: form-group on desktop */
@media (min-width: 600px) {
  .form-group {
    max-width: 420px;
  }
}

/* 7. Form input */
.form-group input {
  width: 100%;
  height: 48px;              /* same height as your button */
  font-size: 1rem;           /* 16px text */
  padding: 0 1rem;           /* 16px on left & right */
  border: 1px solid #bcbcbc; /* light gray border */
  border-radius: 4px;        /* small rounded corners */
  background: #fdfdf7;
  color: var(--color-text);
}


/* — Call-to-action button — */
.cta-button {
  width: 100%;               /* full width under the input */
  height: 48px;              /* same as input */
  font-size: 1rem;           /* 16px text */
  padding: 0 1.5rem;         /* left/right breathing room */
  border: none;
  border-radius: 4px;
  background: #141413;
  color: #fdfdf7;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.cta-button:hover,
.cta-button:focus {
  background: #222;          /* slightly darker on hover/focus */
}

.text-muted {
  font-size: 0.9rem;
  color: var(--color-dark);
  margin-top: 0.5rem;
}

#confirmation {
  margin-top: var(--spacing-unit);
  font-size: 1rem;
  text-align: center;
}

#results {
  list-style: none;
  padding-top: 1rem;
}

.hero-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
  margin: 1.5rem auto;
}
