:root {
  --primary-color: #8d634d;
  --primary-soft: #c99877;
  --secondary-color: #6d7d63;
  --secondary-soft: #d9e2d2;
  --page-bg: #ebe8e1;
  --panel-bg: #f7f3ec;
  --card-bg: #fcf8f2;
  --tag-bg: #efe6dc;
  --border-color: #d7c8b8;
  --text-dark: #2f2119;
  --text-body: #5c4638;
}

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

body {
  font-family: "Inter", Arial, sans-serif;
  background-color: var(--page-bg);
  color: var(--text-dark);
  line-height: 1.6;
}

body.is-loading {
  overflow: hidden;
}

.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--panel-bg);
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.preloader.hide {
  opacity: 0;
  visibility: hidden;
}

.preloader-mark {
  font-family: "Syne", sans-serif;
  font-size: 64px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--primary-color);
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.preloader-mark .angle {
  color: var(--text-body);
}

.preloader-mark .tw {
  animation: twBlink 1s ease-in-out infinite;
}

.preloader-mark .comma {
  color: var(--text-body);
}

@keyframes twBlink {
  from {
    opacity: 0.45;
  }
  to {
    opacity: 1;
  }
}

.navbar {
  background-color: var(--panel-bg);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 16px;
}

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

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex: 1;
}

.logo {
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 0;
  font-size: 14px;
  white-space: nowrap;
}

.nav-links ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.nav-cv-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #fff7f0;
  background-color: var(--primary-color);
  border: 1px solid var(--primary-color);
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(141, 99, 77, 0.18);
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.nav-cv-btn:hover {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
  color: #f3ece5;
}

.nav-links a {
  text-decoration: none;
  color: #4d392d;
  font-size: 14px;
  padding: 6px 10px;
  border-radius: 5px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-links a:hover {
  background-color: var(--secondary-soft);
  color: var(--secondary-color);
}

.hero {
  max-width: 1120px;
  margin: 24px auto;
  background: linear-gradient(90deg, #161311 0%, #161311 48%, #6f4d39 48%, #8d6852 100%);
  border: 1px solid #2a221d;
  border-radius: 18px;
  padding: 0;
  display: flex;
  min-height: 620px;
  overflow: hidden;
}

.hero-panel {
  width: 50%;
  padding: 70px 56px;
  color: #f3ece5;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero h1 {
  font-family: "Syne", sans-serif;
  font-size: 86px;
  line-height: 0.95;
  margin-bottom: 18px;
  letter-spacing: -0.04em;
}

.hero h1 span {
  color: var(--primary-soft);
}

.hero-kicker {
  color: var(--primary-soft);
  font-size: 15px;
  letter-spacing: 0.16em;
  margin-bottom: 18px;
}

.role {
  color: #f7e8da;
  font-weight: 600;
  margin-bottom: 14px;
  font-size: 20px;
}

.role span {
  color: var(--primary-soft);
  margin: 0 8px;
}

.bio {
  color: #d0c1b2;
  margin-bottom: 12px;
  max-width: 440px;
  font-size: 19px;
}

.text-highlight {
  color: var(--primary-soft);
  font-weight: 700;
}

.location {
  color: #b79177;
  margin-bottom: 24px;
  font-size: 15px;
}

.cta-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.cta-buttons a {
  text-decoration: none;
  padding: 12px 20px;
  border-radius: 0;
  font-weight: bold;
  border: 1px solid var(--primary-soft);
  letter-spacing: 0.03em;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.cta-buttons a:first-child {
  background-color: var(--primary-soft);
  color: #161311;
}

.cta-buttons a:last-child {
  background-color: transparent;
  color: #f3ece5;
}

.cta-buttons a:first-child:hover {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
  color: #f3ece5;
}

.cta-buttons a:last-child:hover {
  background-color: var(--secondary-soft);
  border-color: var(--secondary-soft);
  color: var(--secondary-color);
}

.hero-links {
  display: flex;
  gap: 14px;
}

.hero-links a {
  width: 42px;
  height: 42px;
  border: 1px solid #8b6952;
  color: var(--primary-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 20px;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.hero-links a:hover {
  background-color: var(--secondary-soft);
  border-color: var(--secondary-soft);
  color: var(--secondary-color);
}

.hero-visual {
  width: 50%;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  padding: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(0, 0, 0, 0.05));
}

.hero-photo-frame {
  width: 100%;
  height: 100%;
  min-height: 620px;
  display: block;
  overflow: hidden;
}

.hero-photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% center;
  display: block;
  filter: contrast(1.02) saturate(0.95);
}

.section {
  max-width: 1120px;
  margin: 16px auto;
  background: var(--panel-bg);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 22px;
  box-shadow: 0 10px 24px rgba(50, 34, 24, 0.06);
}

.section h2 {
  margin-bottom: 14px;
  font-size: 28px;
  color: var(--text-dark);
}

.section h2 span {
  color: var(--primary-color);
}

.about p {
  color: var(--text-body);
}

.language-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.language-card {
  border: 1px solid var(--border-color);
  background: linear-gradient(180deg, #fffaf4 0%, #f7efe5 100%);
  border-radius: 14px;
  padding: 14px;
  box-shadow: 0 8px 16px rgba(70, 49, 35, 0.08);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.language-card:hover {
  transform: translateY(-2px);
  border-color: var(--secondary-color);
}

.language-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.language-head h3 {
  font-family: "Syne", sans-serif;
  font-size: 22px;
  letter-spacing: 0.02em;
  color: var(--text-dark);
}

.language-level {
  border: 1px solid #cdb9a7;
  background: var(--tag-bg);
  color: #674b3a;
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 700;
}

.ability {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
}

.ability span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #5c4638;
  font-size: 14px;
  font-weight: 600;
}

.ability span i {
  color: var(--primary-color);
  font-size: 18px;
}

.ability-value {
  display: inline-flex;
  align-items: center;
  border: 1px solid #cfbfaf;
  background: #fff8ef;
  color: #5f4334;
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.card-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.card {
  border: 1px solid var(--border-color);
  background-color: var(--tag-bg);
  border-radius: 20px;
  padding: 6px 12px;
  font-weight: 600;
  color: #5a4334;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.card:hover {
  background-color: var(--secondary-soft);
  border-color: #b4c1ab;
  color: var(--secondary-color);
}

.skill-logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 14px;
}

.skill-logo-card {
  border: 1px solid var(--border-color);
  background: var(--card-bg);
  border-radius: 12px;
  padding: 14px 10px;
  text-align: center;
  transition: transform 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.skill-logo-card:hover {
  transform: translateY(-2px);
  border-color: var(--secondary-color);
  /* background-color: var(--secondary-soft); */
  background-color: var(--primary-color);
}

.skill-logo-card img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  display: block;
  margin: 0 auto 10px;
}

.skill-logo-card span {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-dark);
}

.skills-note {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-body);
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 14px;
}

.tool-card {
  border: 1px solid var(--border-color);
  background: var(--card-bg);
  border-radius: 12px;
  padding: 14px 10px;
  text-align: center;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.tool-card:hover {
  border-color: var(--secondary-color);
  background-color: var(--secondary-soft);
  transform: translateY(-2px);
}

.tool-card img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  display: block;
  margin: 0 auto 10px;
}

.tool-card span {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-dark);
}

.tools-note {
  margin-top: 12px;
  color: var(--text-body);
  font-size: 13px;
}

.tools-note a {
  color: var(--primary-color);
  text-decoration: none;
}

.edu-card {
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--primary-color);
  border-radius: 6px;
  padding: 12px;
  margin-bottom: 10px;
  background: var(--card-bg);
  color: #4d392d;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.project-card {
  border: 1px solid var(--border-color);
  padding: 12px;
  background: var(--card-bg);
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.project-card:hover {
  border-color: #b5c0ad;
  box-shadow: 0 10px 22px rgba(62, 78, 56, 0.12);
  transform: translateY(-2px);
}

.project-thumb {
  margin-bottom: 12px;
}

.project-thumb img {
  width: 100%;
  height: 160px;
  display: block;
  border: 1px solid #cdb9a7;
}

.project-copy {
  margin-bottom: 10px;
  flex: 1;
}

.project-card h3 {
  margin-bottom: 8px;
  font-size: 18px;
  color: var(--text-dark);
}

.project-card p {
  color: var(--text-body);
  font-size: 14px;
  margin-bottom: 10px;
}

.project-description {
  margin-bottom: 10px;
}

.project-description p {
  margin-bottom: 0;
}

.tech-stack {
  margin-top: 8px;
}

.tech-stack span {
  display: inline-block;
  border: 1px solid var(--border-color);
  background-color: var(--tag-bg);
  padding: 4px 8px;
  margin-right: 6px;
  margin-bottom: 6px;
  font-size: 13px;
  color: #5a4334;
}

.tech-stack i {
  margin-right: 4px;
  color: var(--primary-color);
}

.project-actions {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid #dfd0c2;
}

.project-actions a {
  display: inline-block;
  text-decoration: none;
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  padding: 8px 10px;
  margin-right: 8px;
  margin-bottom: 8px;
  font-weight: bold;
  background-color: #f7f0e7;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.project-actions a:hover {
  background-color: var(--secondary-soft);
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}

.cert-intro {
  color: var(--text-body);
  margin-bottom: 16px;
}

.cert-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.cert-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  border: 1px solid var(--border-color);
  border-radius: 18px;
  overflow: hidden;
  background: var(--card-bg);
  box-shadow: 0 12px 30px rgba(50, 34, 24, 0.12);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.cert-card:hover {
  transform: translateY(-4px);
  border-color: #b5c0ad;
  box-shadow: 0 14px 28px rgba(62, 78, 56, 0.18);
}

.cert-art {
  padding: 12px;
}

.cert-art img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  background: #fff;
}

.udacity-art {
  background:
    linear-gradient(180deg, rgba(16, 15, 28, 0.25), rgba(16, 15, 28, 0.7)),
    linear-gradient(135deg, #211d4d, #151515);
}

.aws-art {
  background:
    linear-gradient(180deg, rgba(11, 43, 42, 0.2), rgba(11, 43, 42, 0.65)),
    linear-gradient(135deg, #0a5f5c, #0f1f28);
}

.muyalogy-art {
  background:
    linear-gradient(180deg, rgba(17, 103, 176, 0.18), rgba(17, 103, 176, 0.65)),
    linear-gradient(135deg, #0b4d91, #1ea3f2);
}

.skillshare-art {
  background:
    linear-gradient(180deg, rgba(17, 19, 18, 0.25), rgba(17, 19, 18, 0.72)),
    linear-gradient(135deg, #0e1112, #1a2a22);
}

.cert-caption {
  padding: 14px 16px 16px;
  background: var(--card-bg);
}

.cert-caption h3 {
  font-size: 24px;
  line-height: 1.08;
  margin-bottom: 4px;
  color: var(--text-dark);
}

.cert-caption p {
  color: var(--text-body);
  font-size: 14px;
}

.contact-intro {
  margin-bottom: 12px;
  color: var(--text-body);
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 10px;
}

.contact-card {
  text-decoration: none;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: var(--card-bg);
  color: var(--text-dark);
  min-height: 88px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: 10px;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.contact-card:hover {
  border-color: var(--secondary-color);
  background-color: var(--secondary-soft);
  transform: translateY(-2px);
}

.contact-card i {
  font-size: 24px;
  color: var(--primary-color);
  transition: color 0.2s ease;
}

.contact-card span {
  font-size: 12px;
  color: #5c4638;
  font-weight: bold;
}

.contact-card:hover i,
.contact-card:hover span {
  color: var(--secondary-color);
}

footer {
  max-width: 1120px;
  margin: 16px auto 20px;
  background: var(--panel-bg);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 14px;
  text-align: center;
  color: #6a5243;
  font-size: 14px;
}

@media (max-width: 700px) {
  .nav-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-row {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
  }

  .hero {
    flex-direction: column;
    min-height: auto;
    background: #161311;
  }

  .hero-panel,
  .hero-visual {
    width: 100%;
  }

  .hero-panel {
    padding: 44px 24px 28px;
    text-align: left;
  }

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

  .bio {
    font-size: 17px;
  }

  .hero-visual {
    padding: 0;
  }

  .hero-photo-frame {
    min-height: 380px;
  }

  .hero-photo-frame img {
    height: 380px;
    object-position: center top;
  }

  .section h2 {
    font-size: 24px;
  }

  .language-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .cert-gallery {
    grid-template-columns: 1fr;
  }
}
