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

:root {
  --bg-dark: #0c1118;
  --bg-edge: #070a0f;
  --glow: #32f0e3;
  --text: #4a4a4a;
  --text-strong: #1f1f1f;
  --muted: #6c6c6c;
  --border: #303030;
  --accent: #1ec7b8;
  --accent-dark: #10988b;
  --soft-shadow: 0 3px 20px rgba(12, 17, 24, 0.12);
}

html,
body {
  margin: 0;
  padding: 0;
  background: #f6f6f6;
  color: var(--text);
  font-family: "Manrope", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
}

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

a {
  color: inherit;
}

main {
  min-height: 100vh;
}

.container {
  width: min(1160px, 92vw);
  margin: 0 auto;
}

.page--portfolio {
  background: radial-gradient(
      circle at top,
      rgba(30, 199, 184, 0.12),
      transparent 55%
    ),
    #f4f1ea;
}

.page--portfolio main {
  min-height: auto;
}

.page--about {
  background: #ffffff;
}

.page--about h1 {
  text-align: center;
}

.page--about .about__content p {
  text-align: center;
}

.about {
  padding: 60px 0 110px;
  background: #f5f5f5;
}

.about__divider {
  width: min(360px, 80%);
  height: 1px;
  background: #e0dfdd;
  margin: 0 auto 24px;
}

.about__content {
  max-width: 720px;
  margin: 0 auto;
  color: var(--text-strong);
  font-size: 18px;
  line-height: 1.9;
  text-align: left;
}

.about__content p {
  margin-bottom: 28px;
}

.project-gallery {
  margin-top: 40px;
  position: relative;
}

.project-gallery__item {
  margin: 0 0 10px;
  overflow: hidden;
  border-radius: 6px;
  background: #fff;
  break-inside: avoid;
  display: block;
  /* width: 100%; */
  width: calc(25% - 20px);
  position: relative;
}

.project-gallery__item img {
  width: 100%;
  display: block;
  height: auto;
  object-fit: contain;
  cursor: zoom-in;
}

.project-gallery__loader {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.75);
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease;
}

.project-gallery__loader::after {
  content: "";
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 3px solid rgba(16, 152, 139, 0.25);
  border-top-color: var(--accent-dark);
  animation: gallery-spin 0.8s linear infinite;
}

.project-gallery__grid.is-loading + .project-gallery__loader {
  opacity: 1;
}

@keyframes gallery-spin {
  to {
    transform: rotate(360deg);
  }
}

.project-gallery__item[data-type="pdf"]::after {
  content: "";
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 48px;
  height: 48px;
  background: url("assets/pdf_ico.png") no-repeat center / contain;
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(12, 17, 24, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 150ms ease, visibility 150ms ease;
  z-index: 20;
  padding: 24px;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox__image {
  max-width: min(1100px, 92vw);
  max-height: 86vh;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  cursor: zoom-in;
}

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

.lightbox__embed {
  width: min(1100px, 92vw);
  height: 86vh;
  border: none;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.lightbox__video {
  width: min(1100px, 92vw);
  max-height: 86vh;
  border-radius: 8px;
  background: #000000;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.lightbox__embed--video {
  height: auto;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.lightbox.is-embed {
  align-items: center;
}

.lightbox.is-zoomed {
  align-items: flex-start;
}

.lightbox__image.is-zoomed {
  max-width: none;
  max-height: none;
  cursor: zoom-out;
}

.lightbox__close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  font-size: 22px;
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(8px);
}

.nav {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 0;
}

.brand {
  text-decoration: none;
  font-family: "Playfair Display", "Times New Roman", serif;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-strong);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 22px;
}

.nav__links a {
  text-decoration: none;
  font-weight: 500;
  color: var(--text);
  transition: color 150ms ease;
}

.nav__links a:hover {
  color: var(--text-strong);
}

.nav__links a[aria-current="page"] {
  color: var(--accent);
}

.nav__links .nav__cta {
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--accent);
  color: #ffffff;
  font-weight: 600;
}

.nav__checkbox {
  display: none;
}

.nav__toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #ffffff;
  cursor: pointer;
}

.nav__toggle span {
  width: 18px;
  height: 2px;
  background: var(--text-strong);
  display: block;
  margin: 3px 0;
  transition: transform 150ms ease;
}

.portfolio {
  padding-bottom: 80px;
  background: #fff;
}

.portfolio-hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
  padding: 60px 0 28px;
}

.portfolio-hero__eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 12px;
  color: var(--accent-dark);
}

.portfolio-hero h1 {
  margin: 12px 0 18px;
  font-family: "Playfair Display", "Times New Roman", serif;
  font-weight: 600;
  font-size: 44px;
  color: var(--text-strong);
}

.portfolio-hero p {
  margin: 0;
  font-size: 18px;
  line-height: 1.6;
  color: var(--muted);
}

.portfolio-hero__panel {
  background: #ffffff;
  border-radius: 24px;
  padding: 24px 28px;
  box-shadow: var(--soft-shadow);
  display: grid;
  gap: 16px;
}

.portfolio-hero__panel div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.portfolio-hero__panel strong {
  font-size: 28px;
  color: var(--text-strong);
}

.portfolio-hero__panel span {
  font-size: 14px;
  color: var(--muted);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding: 24px 0 40px;
}

.portfolio-card {
  position: relative;
  overflow: hidden;
  background: #ffffff;
  text-decoration: none;
  box-shadow: var(--soft-shadow);
  aspect-ratio: 4 / 3;
  border-radius: 5px;
}

.portfolio-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 350ms ease;
}

.portfolio-card::after {
  content: "";
  position: absolute;
  inset: 0;
  /* background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 40%,
    rgba(0, 0, 0, 0.55) 100%
  ); */
  opacity: 0.65;
  transition: opacity 250ms ease;
}

.portfolio-card__label {
  position: absolute;
  width: 100%;
  left: 0;
  padding: 16px;
  color: #ffffff;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-shadow: 0 6px 14px rgba(0, 0, 0, 1);
  z-index: 1;
  bottom: 0;
  background: #303030;
  opacity: 1;
  transition-duration: 0.5s;
}

.portfolio-card:hover img {
  transform: scale(1.06);
}

.portfolio-card:hover::after {
  opacity: 0.85;
}

.portfolio-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.hero {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  min-height: 100vh;
}

.hero__visual {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    circle at center,
    rgba(50, 240, 227, 0.18) 0%,
    rgba(12, 17, 24, 0.78) 45%,
    var(--bg-dark) 65%,
    var(--bg-edge) 100%
  );
}

.hero__visual::before {
  content: "";
  position: absolute;
  inset: -10% -12%;
  background: radial-gradient(
    circle at 50% 46%,
    rgba(50, 240, 227, 0.2),
    rgba(10, 16, 23, 0.85) 50%,
    rgba(7, 10, 15, 0.95) 70%
  );
  filter: blur(10px);
}

.hero__visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at center,
    rgba(19, 215, 201, 0.12) 0%,
    transparent 45%
  );
  opacity: 0.7;
}

.hero__image {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  filter: drop-shadow(0 25px 35px rgba(0, 0, 0, 0.55));
}

.hero__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero__content {
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 72px 80px;
}

.content__inner {
  max-width: 680px;
  text-align: center;
}

h1 {
  margin: 0 0 28px;
  font-family: "Playfair Display", "Times New Roman", serif;
  font-weight: 600;
  font-size: 48px;
  letter-spacing: 0.015em;
  color: var(--text-strong);
}

.lead {
  margin: 0 0 16px;
  font-size: 18px;
  line-height: 1.65;
  color: var(--muted);
}

.lead:last-of-type {
  margin-bottom: 26px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  margin: 6px 0;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text-strong);
  font-weight: 600;
  text-decoration: none;
  transition: transform 150ms ease, box-shadow 150ms ease,
    border-color 150ms ease;
}

.button:hover {
  background: var(--border);
  color: #fff;
}

.social {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
}

.social__icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #efefef;
  color: var(--text-strong);
  transition: transform 150ms ease, box-shadow 150ms ease,
    border-color 150ms ease;
  text-decoration: none;
}

.social__icon:hover {
  transform: translateY(-1px);
  border-color: #c0c0c0;
}

.social__icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

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

  .hero__content {
    padding: 64px 36px 80px;
  }

  .portfolio-hero {
    grid-template-columns: 1fr;
  }

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

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

  .nav__toggle {
    display: inline-flex;
  }

  .nav__links {
    position: absolute;
    right: 0;
    top: 58px;
    flex-direction: column;
    align-items: flex-start;
    background: #ffffff;
    padding: 16px;
    border-radius: 16px;
    min-width: 220px;
    box-shadow: 0 16px 32px rgba(12, 17, 24, 0.16);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: opacity 150ms ease, transform 150ms ease;
  }

  .nav__checkbox:checked ~ .nav__links {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .nav__links .nav__cta {
    width: 100%;
    text-align: center;
  }
}

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

@media (max-width: 900px) {
  .project-gallery__item {
    width: calc(33% - 20px);
  }
}

@media (max-width: 600px) {
  .project-gallery__item {
    width: calc(50% - 20px);
  }
}

.page--contact {
  background: #fff;
}

.contact {
  padding: 60px 0 110px;
}

.contact-hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: start;
}

.contact-hero__text {
  display: grid;
  gap: 16px;
  align-content: start;
}

.contact-hero__eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 12px;
  color: var(--accent-dark);
}

.contact-hero__text .lead {
  margin: 0;
}

.contact-cards {
  display: grid;
  gap: 16px;
  margin-top: 8px;
}

.contact-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 18px 22px;
  box-shadow: var(--soft-shadow);
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: grid;
  gap: 6px;
}

.contact-card span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent-dark);
}

.contact-card a {
  text-decoration: none;
  font-weight: 600;
  color: var(--text-strong);
}

.contact-card__note {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

.contact-form {
  background: #ffffff;
  border-radius: 24px;
  padding: 28px 32px;
  box-shadow: var(--soft-shadow);
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: grid;
  gap: 18px;
}

.form-field {
  display: grid;
  gap: 8px;
}

.form-field label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
}

.form-field__hidden {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-field input,
.form-field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #d7d7d7;
  background: #fbfbfb;
  font-family: inherit;
  font-size: 16px;
  color: var(--text-strong);
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-field textarea {
  min-height: 140px;
  resize: vertical;
}

.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(30, 199, 184, 0.2);
  background: #ffffff;
}

.button--primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
}

.button--primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: #ffffff;
}

.contact-form__note {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.nav__links .nav__cta[aria-current="page"] {
  color: #ffffff;
}

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

@media (max-width: 720px) {
  .contact-form {
    padding: 24px;
  }
}
