:root {
  --verkstadsgron: #3b4a3f;
  --traockra: #8c6a3b;
  --tegelrost: #a85636;
  --linnevit: #f4f1e8;
  --putsad-beige: #d8d2c4;
  --grafit: #202325;
}

@font-face {
  font-family: "Recoleta";
  src: url("../fonts/Recoleta-Regular.woff2") format("woff2"),
    url("../fonts/Recoleta-Regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Recoleta";
  src: url("../fonts/Recoleta-Medium.woff2") format("woff2"),
    url("../fonts/Recoleta-Medium.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Recoleta";
  src: url("../fonts/Recoleta-SemiBold.woff2") format("woff2"),
    url("../fonts/Recoleta-SemiBold.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Recoleta";
  src: url("../fonts/Recoleta-Bold.woff2") format("woff2"),
    url("../fonts/Recoleta-Bold.woff") format("woff");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("../fonts/Manrope-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--verkstadsgron);
  color: var(--linnevit);
  font-family: "Recoleta", serif;
  line-height: 1.4;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 0.75rem;
  line-height: 1.25;
  color: var(--linnevit);
}

h1 {
  font-size: clamp(2.2rem, 3vw + 1rem, 3.4rem);
  font-weight: 700;
}

h2 {
  font-size: clamp(1.5rem, 1.2vw + 1rem, 2.05rem);
  font-weight: 600;
}

h3 {
  font-size: clamp(1.35rem, 1vw + 1rem, 1.6rem);
  font-weight: 600;
}

h4 {
  font-size: 1rem;
  font-weight: 600;
}

p {
  margin: 0 0 1.25rem;
  font-weight: 400;
  max-width: 70ch;
}

ul {
  margin: 0;
  padding-left: 1.15rem;
  list-style: disc;
}

li {
  margin-bottom: 0.45rem;
}

.container {
  width: min(1100px, calc(100% - 2.5rem));
  margin: 0 auto;
}

.section .container {
  width: min(700px, calc(100% - 2rem));
  margin: 0 auto;
}

.narrow {
  width: min(900px, 100%);
}

.hero {
  position: relative;
  background-color: var(--verkstadsgron);
  background-image: url("../assets/vagg.jpg");
  background-repeat: repeat;
  background-size: 200px 200px;
  background-position: top left;
}

.hero__overlay {
  padding: clamp(3.5rem, 8vw, 6rem) 0;
}

.hero__layout {
  display: flex;
  align-items: center;
  gap: clamp(2rem, 4vw, 4rem);
}

.hero .container {
  width: min(900px, calc(100% - 2.5rem));
}

.brand img {
  display: block;
  width: min(300px, 45vw);
  height: auto;
}

.hero h1 {
  font-size: 48px;
}

.hero__copy p {
  font-size: 28px;
}

.btn {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.75rem 1.6rem;
  background: #a85636;
  color: #f2efe6;
  text-decoration: none;
  border-radius: 999px;
  font-family: "Manrope", "Recoleta", serif;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.btn:hover,
.btn:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.18);
}

.btn:active {
  transform: translateY(0);
}

.section {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0;
}

.section h2,
.section h3,
.section h4 {
  font-size: 30px;
}

.section p,
.section li {
  font-size: 28px;
}

.section--green {
  background: var(--verkstadsgron);
  color: var(--linnevit);
}

.section--rust {
  background: var(--tegelrost);
  color: var(--linnevit);
}

.section--putsad {
  background: var(--putsad-beige);
  color: var(--grafit);
}

.projects-section.section--putsad {
  background: linear-gradient(135deg, #a85636 0%, #b15f3a 50%, #a34f32 100%);
  color: var(--linnevit);
  position: relative;
  overflow: hidden;
}

.projects-section.section--putsad h3,
.projects-section.section--putsad p {
  color: var(--linnevit);
}

.section--putsad h3 {
  color: #1f2324;
}

.section--charcoal {
  background: #202325; 
  color: var(--linnevit);
}

.lead {
  font-size: 1.05rem;
}

.contact {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 1.25rem;
}

.contact__card h4 {
  margin-bottom: 0.3rem;
}

.contact__card p {
  margin: 0;
}

.contact a {
  color: #f2efe6;
  text-decoration: underline;
}

.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.project-card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(244, 241, 232, 0.25);
  border-radius: 28px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.section--putsad .project-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(244, 241, 232, 0.28);
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.28);
  border-color: rgba(244, 241, 232, 0.45);
}

.project-card__thumb {
  padding: 0;
  border: none;
  background: transparent;
  width: 100%;
  cursor: pointer;
}

.project-card__thumb img {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.project-card__body {
  padding: clamp(1.5rem, 3vw, 2rem);
}

.project-card__meta {
  margin: 0 0 0.55rem;
  color: rgba(0, 0, 0, 0.65);
  font-family: "Manrope", "Recoleta", serif;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
}

.section--putsad .project-card__meta {
  color: rgba(32, 35, 37, 0.72);
}

.project-card h4 {
  margin-bottom: 0.5rem;
  color: inherit;
}

.project-card p {
  margin-bottom: 0.95rem;
  color: inherit;
}

.btn--ghost {
  background: transparent;
  color: inherit;
  border: 2px solid rgba(244, 241, 232, 0.6);
  box-shadow: inset 0 12px 24px rgba(0, 0, 0, 0.08);
  border-radius: 999px;
  padding: 0.95rem 1.9rem;
  font-size: 1.05rem;
}

.section--rust .btn--ghost,
.section--charcoal .btn--ghost {
  border-color: rgba(244, 241, 232, 0.4);
}

.project-detail {
  display: none;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 3vh 1rem;
  z-index: 30;
  overflow: auto;
}

.modal[hidden] {
  display: none !important;
}

.modal__dialog {
  background: #3b4a3f;
  color: var(--linnevit);
  max-width: 860px;
  width: min(860px, 100%);
  max-height: calc(100vh - 3rem);
  overflow: auto;
  margin: auto;
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
  position: relative;
  padding: clamp(1.5rem, 3vw, 2rem);
}

.modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: transparent;
  border: 1px solid rgba(244, 241, 232, 0.5);
  color: rgba(244, 241, 232, 0.9);
  font-size: 1.2rem;
  cursor: pointer;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  backdrop-filter: blur(6px);
}

.modal__content h3 {
  color: var(--linnevit);
  margin-bottom: 0.3rem;
}

.modal__meta {
  color: rgba(244, 241, 232, 0.7);
  margin: 0 0 1rem;
  font-family: "Manrope", "Recoleta", serif;
  letter-spacing: 0.01em;
}

.project-detail__layout {
  display: block;
}

.project-gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 1.25rem;
  max-height: 70vh;
  overflow: auto;
  padding-right: 0.25rem;
}

.project-gallery img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.no-scroll {
  overflow: hidden;
}

.footer {
  background: var(--verkstadsgron);
  padding: 2rem 0 2.5rem;
  border-top: 1px solid rgba(244, 241, 232, 0.12);
}

.footer__inner {
  display: flex;
  justify-content: center;
}

.footer img {
  width: 110px;
  height: auto;
  opacity: 0.92;
}

@media (max-width: 900px) {
  .hero__layout {
    flex-direction: column;
    text-align: center;
  }

  .hero__copy {
    max-width: 720px;
  }

  .btn {
    width: fit-content;
  }
}

@media (max-width: 640px) {
  body {
    background: var(--verkstadsgron);
  }

  .container {
    width: min(100%, calc(100% - 2.5rem));
  }

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

  .brand {
    display: flex;
    justify-content: center;
  }

  .btn {
    width: auto;
  }

  .hero h1 {
    font-size: 36px;
  }

  .hero__copy p {
    font-size: 22px;
  }

  .section h2,
  .section h3,
  .section h4 {
    font-size: 26px;
  }

  .section p,
  .section li {
    font-size: 22px;
  }

  .modal__dialog {
    width: 100%;
    margin: 2rem auto;
  }

  .project-card {
    grid-template-columns: 1fr;
  }
}
