/* ==========================================================================
   DiscoverBritainTrails — Stylesheet
   ========================================================================== */

:root {
  --navy: #10263f;
  --navy-dark: #0b1a2c;
  --sky: #8fd0e8;
  --sky-light: #e7f5fa;
  --ivory: #faf6ec;
  --sage: #8ba888;
  --sandstone: #c9a97e;
  --text-main: #1f2b36;
  --text-muted: #51606b;
  --border-color: #e1ddd0;
  --radius: 8px;
}

html {
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Segoe UI", Arial, Helvetica, sans-serif;
  color: var(--text-main);
  background: var(--ivory);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

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

a:hover {
  color: var(--sage);
}

.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4 {
  color: var(--navy);
  margin: 0 0 16px;
  line-height: 1.25;
}

h2 {
  font-size: 2rem;
  text-align: center;
}

.section-intro {
  text-align: center;
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 40px;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  border: 2px solid transparent;
  cursor: pointer;
  text-align: center;
}

.btn-primary {
  background: var(--navy);
  color: #fff;
}

.btn-primary:hover {
  background: var(--navy-dark);
  color: #fff;
}

.btn-outline {
  background: transparent;
  border-color: var(--navy);
  color: var(--navy);
}

.btn-outline:hover {
  background: var(--navy);
  color: #fff;
}

.btn-small {
  padding: 8px 18px;
  font-size: 0.9rem;
}

/* ==========================================================================
   Header / Burger navigation (CSS-only, breakpoint 900px)
   ========================================================================== */

.site-header {
  background: #ffffff;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 500;
}

.nav-container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.brand {
  font-weight: 700;
  font-size: 1.4rem;
  color: var(--navy);
}

.nav-menu {
  display: flex;
  gap: 28px;
}

.nav-menu a {
  font-weight: 600;
  color: var(--text-main);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.nav-menu a:hover {
  color: var(--navy);
  border-color: var(--sandstone);
}

.nav-toggle {
  display: none;
}

.burger-label {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  cursor: pointer;
}

.burger-label span {
  display: block;
  height: 3px;
  width: 100%;
  background: var(--navy);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

@media (max-width: 900px) {
  .burger-label {
    display: flex;
  }

  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    flex-direction: column;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    border-top: 1px solid var(--border-color);
    transition: max-height 0.3s ease;
  }

  .nav-menu a {
    padding: 14px 24px;
    border-bottom: 1px solid var(--border-color);
  }

  .nav-toggle:checked ~ .nav-menu {
    max-height: 420px;
  }

  .nav-toggle:checked ~ .burger-label span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .nav-toggle:checked ~ .burger-label span:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle:checked ~ .burger-label span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  background:
    linear-gradient(180deg, rgba(231, 245, 250, 0.92) 0%, rgba(250, 246, 236, 0.88) 100%),
    url("images/DiscoverBritainTrails-website-background.jpg") center center / cover no-repeat;
  padding: 64px 0;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 48px;
  align-items: center;
}

.hero-text h1 {
  font-size: 2.4rem;
}

.hero-text p {
  color: var(--text-muted);
  margin-bottom: 28px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ==========================================================================
   Section photos (16:9)
   ========================================================================== */

.hero-media,
.content-media {
  min-width: 0;
  width: 100%;
}

.section-photo {
  width: 100%;
  height: auto;
  max-height: none;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(16, 38, 63, 0.12);
}

/* ==========================================================================
   Sections
   ========================================================================== */

.section {
  padding: 72px 0;
}

.section-alt {
  background: #ffffff;
}

.content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

/* Текст слева, фото справа (по умолчанию в разметке) */

.content-grid.reverse {
  grid-template-columns: 1fr 1fr;
}

.content-grid.reverse .content-media {
  order: -1;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.feature-list li {
  padding: 12px 0 12px 20px;
  border-bottom: 1px solid var(--border-color);
  position: relative;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 20px;
  width: 8px;
  height: 8px;
  background: var(--sage);
  border-radius: 50%;
}

.card-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.info-card {
  background: var(--sky-light);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--sky);
  border-radius: var(--radius);
  padding: 20px 22px;
}

.info-card h3 {
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.info-card p {
  margin: 0;
  color: var(--text-muted);
}

/* ==========================================================================
   Reviews
   ========================================================================== */

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.review-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 26px;
}

.stars {
  color: var(--sandstone);
  margin-bottom: 12px;
  letter-spacing: 2px;
}

.review-author {
  margin-top: 16px;
  font-weight: 600;
  color: var(--navy);
}

/* ==========================================================================
   Contact form
   ========================================================================== */

.contact-form {
  max-width: 640px;
  margin: 0 auto;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 32px;
}

.form-row {
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row label {
  font-weight: 600;
  font-size: 0.95rem;
}

.form-row input[type="text"],
.form-row input[type="email"],
.form-row input[type="tel"],
.form-row textarea {
  padding: 11px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  background: var(--ivory);
}

.form-row input:focus,
.form-row textarea:focus {
  outline: 2px solid var(--sky);
  background: #fff;
}

.form-checkbox {
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
}

.form-checkbox input {
  margin-top: 4px;
}

.form-checkbox label {
  font-weight: 400;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.field-error {
  border-color: #c0392b !important;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  background: var(--navy);
  color: #cfdbe6;
  padding: 56px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 32px;
}

.footer-brand {
  color: #ffffff;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.footer-col h4 {
  color: #ffffff;
  font-size: 1rem;
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  color: #cfdbe6;
  margin-bottom: 10px;
}

.footer-col a:hover {
  color: var(--sky);
}

.footer-col address {
  font-style: normal;
  color: #cfdbe6;
  margin-bottom: 14px;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding: 20px 24px;
  text-align: center;
  font-size: 0.9rem;
  color: #9fb2c2;
}

/* ==========================================================================
   Cookie banner
   ========================================================================== */

.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--navy-dark);
  color: #e9eef2;
  z-index: 1000;
  padding: 18px 24px;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.cookie-banner-inner {
  max-width: 1140px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.cookie-banner-inner p {
  margin: 0;
  flex: 1;
  min-width: 240px;
  font-size: 0.92rem;
}

.cookie-banner-inner a {
  color: var(--sky);
  text-decoration: underline;
}

/* ==========================================================================
   Modal
   ========================================================================== */

.modal {
  position: fixed;
  inset: 0;
  background: rgba(16, 38, 63, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1100;
  padding: 20px;
}

.modal[hidden] {
  display: none;
}

.modal-box {
  background: #ffffff;
  border-radius: var(--radius);
  padding: 32px;
  max-width: 420px;
  width: 100%;
  text-align: center;
}

.modal-box h3 {
  margin-bottom: 12px;
}

.modal-box p {
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* ==========================================================================
   Legal pages
   ========================================================================== */

.legal-main {
  max-width: 820px;
  margin: 0 auto;
  padding: 56px 24px 80px;
}

.legal-main h1 {
  font-size: 2rem;
}

.legal-main h2 {
  text-align: left;
  font-size: 1.3rem;
  margin-top: 32px;
}

.legal-main p,
.legal-main li {
  color: var(--text-muted);
}

.legal-main .updated {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 32px;
}

.back-link {
  display: inline-block;
  margin-bottom: 24px;
  font-weight: 600;
}

/* ==========================================================================
   Responsive — Tablet
   ========================================================================== */

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-media {
    order: 1;
  }

  .content-grid,
  .content-grid.reverse {
    grid-template-columns: 1fr;
  }

  .content-grid.reverse .content-media {
    order: 0;
  }

  .reviews-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ==========================================================================
   Responsive — Mobile
   ========================================================================== */

@media (max-width: 600px) {
  h2 {
    font-size: 1.6rem;
  }

  .hero-text h1 {
    font-size: 1.9rem;
  }

  .reviews-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .cookie-banner-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
