/* Inter (variable), self-hosted — те же файлы, что раньше отдавал next/font */
@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-cyrillic-ext.woff2) format("woff2");
  unicode-range:U+0460-052f,U+1c80-1c8a,U+20b4,U+2de0-2dff,U+a640-a69f,U+fe2e-fe2f
}

@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-cyrillic.woff2) format("woff2");
  unicode-range:U+0301,U+0400-045f,U+0490-0491,U+04b0-04b1,U+2116
}

@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-greek-ext.woff2) format("woff2");
  unicode-range:U+1f??
}

@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-greek.woff2) format("woff2");
  unicode-range:U+0370-0377,U+037a-037f,U+0384-038a,U+038c,U+038e-03a1,U+03a3-03ff
}

@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-vietnamese.woff2) format("woff2");
  unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01a0-01a1,U+01af-01b0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1ea0-1ef9,U+20ab
}

@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-latin-ext.woff2) format("woff2");
  unicode-range:U+0100-02ba,U+02bd-02c5,U+02c7-02cc,U+02ce-02d7,U+02dd-02ff,U+0304,U+0308,U+0329,U+1d00-1dbf,U+1e00-1e9f,U+1ef2-1eff,U+2020,U+20a0-20ab,U+20ad-20c4,U+2113,U+2c60-2c7f,U+a720-a7ff
}

@font-face {
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url(../fonts/inter-latin.woff2) format("woff2");
  unicode-range:U+00??,U+0131,U+0152-0153,U+02bb-02bc,U+02c6,U+02da,U+02dc,U+0304,U+0308,U+0329,U+2000-206f,U+20ac,U+2122,U+2191,U+2193,U+2212,U+2215,U+feff,U+fffd
}


/* Метрики Arial подогнаны под Inter, чтобы не было скачка вёрстки до загрузки шрифта */
@font-face {
  font-family: "Inter Fallback";
  src: local("Arial");
  ascent-override: 90.2%;
  descent-override: 22.48%;
  line-gap-override: 0%;
  size-adjust: 107.4%;
}

:root {
  --accent: #69b8d0;
  --accent-2: #4a9fd1;
  --accent-3: #2c5aa0;
  --panel-bg: linear-gradient(135deg, rgba(15, 32, 39, 0.8) 0%, rgba(32, 58, 67, 0.6) 100%);
  --panel-border: 1px solid rgba(105, 184, 208, 0.2);
}

/* ---------- Base ---------- */

html,
body {
  margin: 0;
  padding: 0;
  font-family: "Inter", "Inter Fallback", sans-serif;
  font-size: 18px;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  background-color: black;
  background-image: linear-gradient(#0F2027, #203A43, #2C5364);
  background-position: center;
  background-repeat: no-repeat;
}

/* ---------- Header ---------- */

.header {
  height: 100vh;
  position: relative;
}

.header__text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  color: white;
  text-align: center;
}

.header__text h1,
.header__text h2 {
  margin: 0;
  padding: 0;
}

.header__text_main {
  font-size: 28px;
  text-transform: uppercase;
}

.header__text_main .name {
  color: white;
}

.header__text_main .surname {
  color: var(--accent);
}

.header__text_description {
  position: relative;
  font-size: 17px;
}

.header__text_description .text::after {
  position: absolute;
  content: '';
  height: 2px;
  bottom: -6px;
  margin: 0 auto;
  left: 0;
  right: 0;
  width: 200px;
  background: var(--accent);
  transition: 0.3s;
}

.header__text_description .text:hover::after {
  width: 250px;
}

.header__social {
  height: 40px;
  padding-top: 20px;
  display: flex;
  justify-content: center;
  gap: 20px;
}

.header__arrow {
  height: 40px;
  cursor: pointer;
  position: absolute;
  left: 50%;
  bottom: 40px;
  transform: translateX(-50%);
}

.header__arrow img {
  max-height: 100%;
}

/* ---------- Sections ---------- */

.section {
  background: var(--panel-bg);
  border-radius: 20px;
  margin: 40px 20px;
  padding: 40px 20px;
  backdrop-filter: blur(10px);
  border: var(--panel-border);
}

.sectionTitle {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 40px 0;
  padding: 20px 0;
  position: relative;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 50%, var(--accent-3) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 30px rgba(105, 184, 208, 0.3);
  letter-spacing: 2px;
  text-transform: uppercase;
  animation: titleGlow 3s ease-in-out infinite alternate;
  cursor: default;
  transition: all 0.3s ease;
}

.sectionTitle:hover {
  transform: scale(1.05);
  animation-duration: 1s;
}

.sectionTitle::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: linear-gradient(135deg, rgba(105, 184, 208, 0.1) 0%, rgba(44, 90, 160, 0.1) 100%);
  border-radius: 20px;
  z-index: -1;
  opacity: 0.6;
  filter: blur(20px);
  transition: all 0.3s ease;
}

.sectionTitle:hover::before {
  opacity: 0.8;
  filter: blur(30px);
  transform: translate(-50%, -50%) scale(1.1);
}

.sectionTitle::after {
  content: '';
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  border-radius: 2px;
  animation: underlineGlow 2s ease-in-out infinite alternate;
  transition: all 0.3s ease;
}

.sectionTitle:hover::after {
  width: 120px;
  height: 6px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent-2), transparent);
}

@keyframes titleGlow {
  0% { text-shadow: 0 0 30px rgba(105, 184, 208, 0.3); }
  50% { text-shadow: 0 0 40px rgba(105, 184, 208, 0.5), 0 0 60px rgba(105, 184, 208, 0.2); }
  100% { text-shadow: 0 0 50px rgba(105, 184, 208, 0.6), 0 0 80px rgba(105, 184, 208, 0.3); }
}

@keyframes underlineGlow {
  0% { box-shadow: 0 0 10px rgba(105, 184, 208, 0.3); transform: translateX(-50%) scaleX(0.8); }
  50% { box-shadow: 0 0 15px rgba(105, 184, 208, 0.5); transform: translateX(-50%) scaleX(1); }
  100% { box-shadow: 0 0 20px rgba(105, 184, 208, 0.6); transform: translateX(-50%) scaleX(1.2); }
}

/* ---------- Projects ---------- */

.projects__cards {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: center;
  margin: 0 auto;
}

.project {
  min-width: 350px;
  max-width: 450px;
  flex: 1;
  font-size: 0.8rem;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border-radius: 20px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
  backdrop-filter: blur(10px);
  border: var(--panel-border);
}

.project:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 50px rgba(105, 184, 208, 0.3);
}

.project__imageContainer {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  padding: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.project__image {
  width: 200px;
  height: 200px;
  margin: auto;
}

.project__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.project__description {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 25px;
  background: linear-gradient(135deg, rgba(239, 250, 255, 0.95) 0%, rgba(245, 245, 245, 0.9) 100%);
  flex: 1;
  position: relative;
  z-index: 1;
}

.project__title {
  text-align: center;
  font-weight: 700;
  font-size: 1.2rem;
  padding: 15px 0;
  margin: 0 0 10px;
  color: #2c3e50;
  line-height: 1.3;
}

.project__text {
  text-align: justify;
  color: #34495e;
  line-height: 1.6;
  margin: 0 0 15px;
}

.project__skills {
  display: flex;
  flex-direction: column;
  padding: 15px 0;
  margin-bottom: 15px;
}

.project__skills::before {
  content: attr(data-label);
  font-weight: 700;
  font-size: 1rem;
  color: #2c3e50;
  margin-bottom: 12px;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(105, 184, 208, 0.1) 0%, rgba(105, 184, 208, 0.05) 100%);
  border-radius: 12px;
  border-left: 4px solid var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.project__skills ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 8px 0;
  color: #2c3e50;
  font-weight: 500;
  list-style: none;
  padding: 0;
}

.project__skills li {
  display: flex;
  align-items: center;
  padding: 8px 14px;
  background: rgba(105, 184, 208, 0.08);
  border-radius: 20px;
  border: 1px solid rgba(105, 184, 208, 0.15);
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.project__skills li:hover {
  background: rgba(105, 184, 208, 0.12);
  transform: translateX(5px);
  border-color: rgba(105, 184, 208, 0.3);
}

.project__skills li::before {
  content: '•';
  color: var(--accent);
  font-weight: bold;
  margin-right: 8px;
  font-size: 1.2rem;
}

.project__icons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
}

.project__icons a {
  height: 40px;
  display: flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(105, 184, 208, 0.2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.project__icons img {
  height: 100%;
  object-fit: contain;
  transition: all 0.3s ease;
}

.project__icons a:hover {
  transform: translateY(-3px) scale(1.05);
  background: rgba(105, 184, 208, 0.1);
  border-color: rgba(105, 184, 208, 0.4);
  box-shadow: 0 4px 15px rgba(105, 184, 208, 0.2);
}

.project__icons a:hover img {
  transform: scale(1.1);
}

.project__url {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin-top: 15px;
}

.project__url a {
  color: #3498db;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project__url a:hover {
  color: #2980b9;
  text-decoration: underline;
}

.project__badges {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 15px;
}

.project__badges a {
  transition: transform 0.3s ease;
}

.project__badges a:hover {
  transform: translateY(-3px) scale(1.05);
}

.project__underConstruction {
  display: flex;
  justify-content: center;
  color: #e74c3c;
  font-style: italic;
  font-size: 0.9rem;
  font-weight: 600;
  margin-top: 10px;
  padding: 8px 16px;
  background: rgba(231, 76, 60, 0.1);
  border-radius: 20px;
  border: 1px solid rgba(231, 76, 60, 0.3);
}

/* ---------- Presentations ---------- */

.presentations__cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 30px;
  justify-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

.presentations__cards iframe {
  width: 100%;
  max-width: 560px;
  height: 315px;
  border: 0;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.presentations__cards iframe:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(105, 184, 208, 0.3);
}

/* ---------- Articles ---------- */

.articles__list {
  display: flex;
  flex-direction: column;
  gap: 25px;
  max-width: 900px;
  margin: 0 auto;
}

.article__item {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.03) 100%);
  border-radius: 15px;
  padding: 25px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: var(--panel-border);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.article__item::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(105, 184, 208, 0.1), transparent);
  transition: left 0.6s ease;
}

.article__item:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.06) 100%);
  border-color: var(--accent);
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 15px 40px rgba(105, 184, 208, 0.25);
}

.article__item:hover::before {
  left: 100%;
}

.article__link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.article__title {
  color: white;
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 15px 0;
  line-height: 1.4;
  transition: all 0.3s ease;
  position: relative;
  z-index: 1;
}

.article__title:hover {
  color: var(--accent);
  text-shadow: 0 0 10px rgba(105, 184, 208, 0.5);
}

.article__description {
  color: rgba(255, 255, 255, 0.85);
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
  position: relative;
  z-index: 1;
  transition: color 0.3s ease;
}

.article__description:hover {
  color: rgba(255, 255, 255, 0.95);
}

/* ---------- Responsive ---------- */

@media (min-width: 425px) {
  .header__text_main { font-size: 40px; }
  .header__text_description { font-size: 24px; }
}

@media (min-width: 650px) {
  .project { font-size: 1rem; }
}

@media (min-width: 860px) {
  .header__text_main { font-size: 60px; }
  .header__text_description { font-size: 27px; }
  .projects__cards { gap: 40px; }
  .presentations__cards { gap: 40px; }
  .articles__list { max-width: 1000px; }
  .article__title { font-size: 22px; }
  .article__description { font-size: 17px; }
}

@media (max-width: 768px) {
  .section {
    margin: 20px 10px;
    padding: 30px 15px;
  }

  .sectionTitle {
    font-size: 2rem;
    letter-spacing: 1px;
    margin: 0 0 30px 0;
    padding: 15px 0;
  }

  .projects__cards { gap: 20px; }

  .presentations__cards {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .presentations__cards iframe { height: 250px; }

  .article__item { padding: 20px; }
  .article__title { font-size: 18px; }
  .article__description { font-size: 15px; }
}

@media (max-width: 480px) {
  .sectionTitle {
    font-size: 1.8rem;
    letter-spacing: 0.5px;
  }
}

@media (max-width: 425px) {
  .project {
    max-width: 100%;
  }
}
