:root {
  --color-brick-red: #B22222;
  --color-brick-red-dark: #8B1A1A;
  --color-cream: #FFFDD0;
  --color-petrol: #008080;
  --color-graphite: #36454F;
  --color-graphite-light: #4A5A65;
  --color-white: #FFFFFF;

  --font-heading: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  --text-display: clamp(2.5rem, 5vw + 1rem, 3.5rem);
  --text-h1: clamp(2rem, 3.5vw + 0.75rem, 2.5rem);
  --text-h2: clamp(1.75rem, 2.5vw + 0.5rem, 2rem);
  --text-h3: clamp(1.375rem, 1.5vw + 0.5rem, 1.5rem);
  --text-h4: clamp(1.125rem, 1vw + 0.5rem, 1.25rem);
  --text-body: 1rem;
  --text-small: 0.875rem;

  --leading-display: 4rem;
  --leading-h1: 3rem;
  --leading-h2: 2.5rem;
  --leading-h3: 2rem;
  --leading-h4: 1.75rem;
  --leading-body: 1.6rem;
  --leading-small: 1.25rem;

  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  --space-4xl: 96px;

  --container-max: 1200px;
  --container-margin: 24px;

  --radius-none: 0px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;

  --shadow-card: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-card-hover: 0 6px 16px rgba(0, 0, 0, 0.14);

  --border-petrol: 1px solid var(--color-petrol);
  --border-graphite: 1px solid var(--color-graphite);
  --border-graphite-light: 1px solid var(--color-graphite-light);
}

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  color: var(--color-graphite);
  background-color: var(--color-cream);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

button {
  background: none;
  border: none;
  cursor: pointer;
}

a {
  color: var(--color-petrol);
  text-decoration: none;
}

a:hover {
  color: var(--color-brick-red);
}

ul,
ol {
  list-style-position: inside;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-graphite);
  margin-block-end: var(--space-md);
}

h1 {
  font-size: var(--text-h1);
  line-height: var(--leading-h1);
  margin-block-end: var(--space-lg);
}

h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-md);
}

h3 {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  margin-block-end: var(--space-sm);
}

h4 {
  font-size: var(--text-h4);
  line-height: var(--leading-h4);
  margin-block-end: var(--space-sm);
}

p {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  margin-block-end: var(--space-md);
}

small {
  font-size: var(--text-small);
  line-height: var(--leading-small);
}

blockquote {
  margin-block-end: var(--space-md);
  padding-inline-start: var(--space-lg);
  border-inline-start: 4px solid var(--color-petrol);
  color: var(--color-graphite-light);
}

figure {
  margin-block-end: var(--space-md);
}

figcaption {
  font-size: var(--text-small);
  line-height: var(--leading-small);
  color: var(--color-graphite-light);
  margin-block-start: var(--space-sm);
}

hr {
  border: none;
  border-top: 1px solid var(--color-graphite-light);
  margin-block: var(--space-xl);
}

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

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--text-body);
  line-height: 1.2;
  padding: var(--space-md) var(--space-xl);
  border-radius: var(--radius-sm);
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 0 100%);
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
  text-align: center;
  min-height: 48px;
}

.btn:focus-visible {
  outline: 2px solid var(--color-brick-red);
  outline-offset: 2px;
}

.btn-primary {
  background-color: var(--color-brick-red);
  color: var(--color-white);
}

.btn-primary:hover {
  background-color: var(--color-brick-red-dark);
  color: var(--color-white);
}

.btn-secondary {
  background-color: var(--color-petrol);
  color: var(--color-white);
}

.btn-secondary:hover {
  background-color: var(--color-graphite-light);
  color: var(--color-white);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-petrol);
  border: 1px solid var(--color-petrol);
}

.btn-outline:hover {
  background-color: var(--color-petrol);
  color: var(--color-white);
}

.card {
  background-color: var(--color-white);
  border: var(--border-graphite);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  padding: var(--space-lg);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card > :last-child {
  margin-block-end: 0;
}

.surface-light {
  background-color: var(--color-cream);
  color: var(--color-graphite);
}

.surface-dark {
  background-color: var(--color-graphite);
  color: var(--color-cream);
}

.surface-petrol {
  background-color: var(--color-petrol);
  color: var(--color-white);
}

.surface-white {
  background-color: var(--color-white);
  color: var(--color-graphite);
}

.text-brick {
  color: var(--color-brick-red);
}

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

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

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

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

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

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

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

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

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

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

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

.flex-1 {
  flex: 1 1 0%;
  min-width: 0;
}

.flex-auto {
  flex: 0 0 auto;
  min-width: 0;
}

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

.grid-auto > * {
  min-width: 0;
}

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

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

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

.grid-2 > *,
.grid-3 > *,
.grid-4 > * {
  min-width: 0;
}

.content-list {
  margin-block-end: var(--space-md);
  padding-inline-start: var(--space-lg);
}

.content-list li {
  margin-block-end: var(--space-sm);
}

.content-list li:last-child {
  margin-block-end: 0;
}

.content-list > :last-child {
  margin-block-end: 0;
}

input,
textarea,
select {
  width: 100%;
  padding: var(--space-sm) var(--space-md);
  border: none;
  border-bottom: 2px solid var(--color-graphite-light);
  background-color: transparent;
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  color: var(--color-graphite);
  transition: border-color 0.2s ease;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-bottom-color: var(--color-brick-red);
}

input::placeholder,
textarea::placeholder {
  color: var(--color-graphite-light);
  opacity: 0.7;
}

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

label {
  display: block;
  font-weight: 500;
  margin-block-end: var(--space-xs);
  color: var(--color-graphite);
}

fieldset {
  border: 1px solid var(--color-graphite-light);
  border-radius: var(--radius-sm);
  padding: var(--space-md);
  margin-block-end: var(--space-md);
}

legend {
  font-family: var(--font-heading);
  font-weight: 700;
  padding-inline: var(--space-sm);
}

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

@media (max-width: 768px) {
  :root {
    --container-margin: 16px;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .flex {
    flex-wrap: wrap;
  }

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