:root {
  --green-1: #eaf6ee;
  --green-2: #bfe4cb;
  --green-3: #8fcda3;
  --green-4: #4c8a63;
  --ink: #14201a;
  --card-bg: rgba(255, 255, 255, 0.62);
  --card-bg-solid: #ffffff;
  --card-border: rgba(20, 32, 26, 0.08);
  --shadow: 0 10px 30px rgba(20, 32, 26, 0.12);
  --radius-lg: 22px;
  --radius-md: 16px;
  --max-w: 620px;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: linear-gradient(160deg, var(--green-1) 0%, var(--green-2) 45%, var(--green-3) 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.bg-decor {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(600px circle at 85% -5%, rgba(255, 255, 255, 0.55), transparent 60%),
    radial-gradient(500px circle at -10% 30%, rgba(255, 255, 255, 0.35), transparent 60%);
}

.page {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 48px 20px 40px;
}

/* Profile */
.profile {
  text-align: center;
  margin-bottom: 32px;
}

.avatar {
  width: 128px;
  height: 128px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  margin: 0 auto 16px;
  border: 3px solid rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow);
}

.name {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}

.bio {
  font-size: 0.98rem;
  line-height: 1.55;
  margin: 0 auto;
  max-width: 480px;
  color: var(--ink);
  opacity: 0.85;
}

/* Section titles */
.section-title {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.6;
  margin: 0 0 12px;
  text-align: center;
}

section + section {
  margin-top: 36px;
}

/* Social links */
.links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: var(--card-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.18s ease, background 0.18s ease;
}

.link-card:hover,
.link-card:focus-visible {
  transform: translateY(-2px);
  background: var(--card-bg-solid);
}

.link-icon {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--green-4);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.link-icon svg {
  width: 20px;
  height: 20px;
}

.link-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.link-title {
  font-weight: 600;
  font-size: 0.98rem;
}

.link-desc {
  font-size: 0.84rem;
  opacity: 0.7;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Donate */
.donate-row {
  display: flex;
  gap: 12px;
}

.donate-card {
  flex: 1;
  text-align: center;
  padding: 14px 12px;
  background: var(--green-4);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, filter 0.18s ease;
}

.donate-card:hover,
.donate-card:focus-visible {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

/* Projects — scattered cards */
.projects-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 22px 18px;
  justify-content: center;
  padding: 6px 4px 14px;
}

.project-card {
  flex: 1 1 240px;
  max-width: 300px;
  padding: 20px;
  background: var(--card-bg-solid);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.card-1 { transform: rotate(-3deg) translateY(2px); }
.card-2 { transform: rotate(2.5deg) translateY(-6px); }
.card-3 { transform: rotate(2deg) translateY(4px); }
.card-4 { transform: rotate(-2.5deg) translateY(-4px); }
.card-5 { transform: rotate(1.8deg) translateY(-8px); }
.card-6 { transform: rotate(-1.5deg) translateY(10px); }

.project-card:hover,
.project-card:focus-visible {
  transform: rotate(0deg) translateY(-4px) scale(1.02);
  box-shadow: 0 16px 34px rgba(20, 32, 26, 0.18);
}

.project-title {
  font-weight: 700;
  font-size: 1.02rem;
  line-height: 1.3;
}

.project-desc {
  font-size: 0.86rem;
  opacity: 0.75;
  line-height: 1.45;
}

.project-card.is-placeholder {
  opacity: 0.55;
  cursor: default;
}

.project-card.is-placeholder:hover {
  transform: rotate(-1.5deg) translateY(10px);
  box-shadow: var(--shadow);
}

@media (max-width: 420px) {
  .card-1 { transform: rotate(-1.2deg); }
  .card-2 { transform: rotate(1deg); }
  .card-3 { transform: rotate(0.8deg); }
  .card-4 { transform: rotate(-0.9deg); }
  .card-5 { transform: rotate(0.7deg); }
  .card-6 { transform: rotate(-0.6deg); }
}

/* Contact form */
.contact-title {
  text-transform: none;
  font-size: 1.15rem;
  font-weight: 700;
  opacity: 1;
  letter-spacing: -0.01em;
  margin-bottom: 18px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--card-bg-solid);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 22px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.86rem;
  font-weight: 600;
  opacity: 0.85;
}

.field input,
.field textarea {
  font-family: inherit;
  font-size: 0.98rem;
  font-weight: 400;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(20, 32, 26, 0.15);
  background: #f7faf8;
  color: var(--ink);
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--green-4);
  outline-offset: 1px;
}

.hp-field {
  position: absolute;
  left: -5000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.submit-btn {
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  background: var(--green-4);
  border: none;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: filter 0.18s ease, transform 0.18s ease;
}

.submit-btn:hover,
.submit-btn:focus-visible {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.form-note {
  margin: 0;
  font-size: 0.86rem;
  min-height: 1.2em;
  opacity: 0.8;
}

/* Footer */
.footer {
  text-align: center;
  margin-top: 40px;
  font-size: 0.8rem;
  opacity: 0.55;
}

@media (min-width: 640px) {
  .avatar {
    width: 152px;
    height: 152px;
  }
  .name {
    font-size: 1.75rem;
  }
}
