/* ========================================
   Variables & Reset
   ======================================== */
:root {
  --bg: #f2f2f2;
  --text: #2e2e2e;
  --accent: #ffaa81;
  --white: #ffffff;
  --heading-font: 'Droid Serif', Georgia, serif;
  --body-font: 'Open Sans', Arial, sans-serif;
  --section-padding: 80px;
  --content-gap: 48px;
  --container-width: 1100px;
}

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

body {
  font-family: var(--body-font);
  color: var(--text);
  background-color: var(--bg);
  line-height: 1.7;
  font-weight: 300;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}

a:hover {
  opacity: 0.8;
}

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

/* ========================================
   Layout
   ======================================== */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: var(--section-padding) 0;
}

.section:first-child {
  padding-top: calc(64px + var(--section-padding));
}

.section:nth-child(even) {
  background: var(--white);
}

.section h2 {
  font-family: var(--heading-font);
  font-size: 2rem;
  margin-bottom: 40px;
  text-align: center;
  position: relative;
}

.section h2::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--accent);
  margin: 12px auto 0;
}

/* ========================================
   Navbar
   ======================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--white);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.nav-container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-logo {
  font-family: var(--heading-font);
  font-size: 1.25rem;
  color: var(--text);
  font-weight: 700;
}

.nav-logo:hover {
  opacity: 1;
  color: var(--accent);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 32px;
}

.nav-links a {
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
  opacity: 1;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: transform 0.3s, opacity 0.3s;
}

/* ========================================
   Text Block
   ======================================== */
.text-with-image {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--content-gap);
  align-items: start;
}

.text-with-image.text-image-right {
  grid-template-columns: 1fr 280px;
}

.text-with-image.text-image-right .text-image-figure {
  order: 2;
}

.text-with-image.text-image-right .text-image-body {
  order: 1;
}

.text-image-body p {
  margin-bottom: 16px;
}

.text-image-body p:last-child {
  margin-bottom: 0;
}

.text-body p {
  margin-bottom: 16px;
}

.text-body p:last-child {
  margin-bottom: 0;
}

/* ========================================
   Photo Block
   ======================================== */
.photo-figure {
  margin: 0 auto;
}

.photo-figure img {
  border-radius: 4px;
}

.photo-figure figcaption {
  text-align: center;
  margin-top: 12px;
  font-size: 0.85rem;
  color: #888;
}

.photo-small {
  max-width: 400px;
}

.photo-medium {
  max-width: 700px;
}

.photo-full {
  max-width: 100%;
}

/* ========================================
   Photo Grid Block
   ======================================== */
.photo-grid {
  display: grid;
  gap: 16px;
}

.photo-grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.photo-grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.photo-grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.photo-grid-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 4px;
}

.photo-grid-item figcaption {
  text-align: center;
  margin-top: 8px;
  font-size: 0.85rem;
  color: #888;
}

/* ========================================
   Links Block
   ======================================== */
.links-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

/* ========================================
   Contact Block
   ======================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--content-gap);
  align-items: start;
}

.contact-info p {
  margin-bottom: 16px;
}

.contact-email a {
  font-size: 1.1rem;
  font-weight: 600;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: var(--body-font);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--white);
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
}

/* ========================================
   Buttons
   ======================================== */
.btn {
  display: inline-block;
  padding: 14px 36px;
  background: var(--accent);
  color: var(--white);
  border: none;
  border-radius: 4px;
  font-family: var(--body-font);
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: background 0.2s;
}

.btn:hover {
  background: #e8955f;
  color: var(--white);
  opacity: 1;
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background: var(--text);
  color: rgba(255, 255, 255, 0.7);
  padding: 32px 0;
}

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

.footer-content p {
  font-size: 0.85rem;
}

.social-links {
  display: flex;
  gap: 20px;
}

.social-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
}

.social-links a:hover {
  color: var(--accent);
  opacity: 1;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 768px) {
  /* Mobile navigation */
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    gap: 0;
    padding: 8px 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links li a {
    display: block;
    padding: 12px 24px;
  }

  /* Text with image — inline (image above text, centered) */
  .text-with-image.mobile-image-inline {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .text-with-image.mobile-image-inline .text-image-figure {
    order: 0;
  }

  .text-with-image.mobile-image-inline .text-image-body {
    order: 0;
    text-align: left;
  }

  .text-with-image.mobile-image-inline .text-image-figure img {
    width: 220px;
    height: auto;
    border-radius: 4px;
  }

  /* Text with image — show (keep side-by-side, shrink image) */
  .text-with-image.mobile-image-show {
    grid-template-columns: 120px 1fr;
  }

  .text-with-image.mobile-image-show.text-image-right {
    grid-template-columns: 1fr 120px;
  }

  /* Text with image — hide */
  .text-with-image.mobile-image-hide .text-image-figure {
    display: none;
  }

  .text-with-image.mobile-image-hide {
    grid-template-columns: 1fr;
  }

  /* Photo grid */
  .photo-grid-3,
  .photo-grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .contact-form .btn {
    width: 100%;
  }

  /* Links */
  .links-list {
    flex-direction: column;
    align-items: stretch;
  }

  .links-list .btn {
    text-align: center;
  }

  /* Footer */
  .footer-content {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .section {
    padding: calc(var(--section-padding) * 0.7) 0;
  }

  .section:first-child {
    padding-top: calc(64px + var(--section-padding) * 0.7);
  }

  .section h2 {
    font-size: 1.6rem;
  }

  .text-with-image.mobile-image-inline .text-image-figure img {
    width: 180px;
  }

  .text-with-image.mobile-image-show {
    grid-template-columns: 90px 1fr;
  }

  .text-with-image.mobile-image-show.text-image-right {
    grid-template-columns: 1fr 90px;
  }

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