/* Rohit Dalal portfolio — production-focused, light/dark, no framework */

:root {
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius: 12px;
  --radius-lg: 16px;
  --max: 1360px;
  --page-pad: clamp(1rem, 4vw, 2.75rem);
  --header-h: 4rem;
}

/* —— Light theme (default) —— */
[data-theme="light"] {
  --bg: #fafafa;
  --bg-elevated: #ffffff;
  --text: #0f172a;
  --text-secondary: #475569;
  --border: #e2e8f0;
  --accent: #0d9488;
  --accent-hover: #0f766e;
  --accent-muted: rgba(13, 148, 136, 0.12);
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  --shadow-md: 0 12px 40px rgba(15, 23, 42, 0.1);
  --hero-accent: linear-gradient(135deg, #0d9488 0%, #0e7490 100%);
}

/* —— Dark theme —— */
[data-theme="dark"] {
  --bg: #0a0c10;
  --bg-elevated: #12151c;
  --text: #f1f5f9;
  --text-secondary: #94a3b8;
  --border: rgba(148, 163, 184, 0.18);
  --accent: #2dd4bf;
  --accent-hover: #5eead4;
  --accent-muted: rgba(45, 212, 191, 0.12);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 16px 48px rgba(0, 0, 0, 0.45);
  --hero-accent: linear-gradient(135deg, #14b8a6 0%, #06b6d4 100%);
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
}

.nowrap {
  white-space: nowrap;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--accent-hover);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 9999;
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 1rem;
}

/* —— Layout —— */
.layout {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--page-pad);
}

.layout--hero {
  position: relative;
  padding-top: 1.5rem;
  overflow: hidden;
  isolation: isolate;
}

.layout--hero::before {
  content: "";
  position: absolute;
  inset: -25% -15% auto -15%;
  height: 85%;
  background: radial-gradient(
      ellipse 75% 55% at 12% 18%,
      color-mix(in srgb, var(--accent) 16%, transparent),
      transparent 68%
    ),
    radial-gradient(
      ellipse 55% 45% at 88% 12%,
      color-mix(in srgb, var(--accent) 10%, transparent),
      transparent 62%
    );
  pointer-events: none;
  z-index: 1;
}

.layout--hero > * {
  position: relative;
  z-index: 2;
}

.config-error {
  margin: 0;
  padding: 1rem var(--page-pad) 0;
  color: #b91c1c;
  font-size: 0.95rem;
}

[data-theme="dark"] .config-error {
  color: #fca5a5;
}

.config-error code {
  font-size: 0.85em;
}

/* —— Header —— */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  /* Solid-ish bar on small screens: backdrop-filter here breaks `position: fixed`
     on the mobile nav (fixed child is clipped to the short header). */
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  border-bottom: 1px solid var(--border);
}

@media (min-width: 900px) {
  .header {
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
  }
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--page-pad);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.brand:hover {
  color: var(--accent);
  text-decoration: none;
}

.brand__img {
  border-radius: 8px;
  box-shadow: 0 0 0 1px var(--border);
}

.nav {
  display: none;
  align-items: center;
  gap: clamp(0.65rem, 1.5vw, 1.15rem);
  font-size: 0.88rem;
  font-weight: 500;
}

.nav a {
  color: var(--text-secondary);
  text-decoration: none;
  padding: 0.35rem 0;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.nav a:hover {
  color: var(--text);
  text-decoration: none;
}

.nav a.nav__active {
  color: var(--text);
  font-weight: 600;
  border-bottom-color: var(--accent);
}

.nav__cta.nav__active {
  border-bottom-color: transparent;
}

.nav__cta {
  padding: 0.4rem 0.85rem !important;
  margin-bottom: 0 !important;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--border)) !important;
  background: var(--accent-muted);
  color: var(--accent) !important;
  font-weight: 600;
}

.nav__cta:hover {
  border-color: var(--accent) !important;
  color: var(--accent-hover) !important;
}

@media (min-width: 900px) {
  .nav {
    display: flex;
  }
}

/* Mobile nav overlay */
@media (max-width: 899px) {
  .header--open .nav {
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0;
    right: 0;
    top: var(--header-h);
    bottom: 0;
    padding: 1.5rem 1.5rem max(1.5rem, env(safe-area-inset-bottom));
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    gap: 0;
    box-shadow: var(--shadow-md);
    z-index: 110;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    animation: navIn 0.2s ease-out;
  }

  @keyframes navIn {
    from {
      opacity: 0;
      transform: translateY(-8px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  .header--open .nav a {
    padding: 1rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 1.05rem;
  }

  .header--open .nav a:last-child {
    border-bottom: none;
  }
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.lang-select {
  appearance: none;
  max-width: 9.25rem;
  padding: 0.35rem 1.75rem 0.35rem 0.55rem;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  line-height: 1.2;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23475569' d='M0 0h10L5 6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.45rem center;
  background-size: 9px 5px;
}

[data-theme="dark"] .lang-select {
  color: var(--text-secondary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%2394a3b8' d='M0 0h10L5 6z'/%3E%3C/svg%3E");
}

.lang-select:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
  color: var(--text);
}

@media (max-width: 400px) {
  .lang-select {
    max-width: 7.5rem;
    font-size: 0.75rem;
    padding-right: 1.5rem;
  }
}

.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (min-width: 900px) {
  .menu-toggle {
    display: none;
  }
}

.header--open .menu-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header--open .menu-toggle span:nth-child(2) {
  opacity: 0;
}

.header--open .menu-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.theme-toggle {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  cursor: pointer;
  color: var(--text);
}

.theme-toggle:hover {
  border-color: var(--accent);
}

.theme-toggle__icon {
  grid-area: 1 / 1;
  font-size: 1.1rem;
  line-height: 1;
}

[data-theme="light"] .theme-toggle__icon--moon {
  opacity: 1;
}

[data-theme="light"] .theme-toggle__icon--sun {
  opacity: 0;
}

[data-theme="dark"] .theme-toggle__icon--sun {
  opacity: 1;
}

[data-theme="dark"] .theme-toggle__icon--moon {
  opacity: 0;
}

/* —— Buttons —— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none !important;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.15s;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: var(--hero-accent);
  color: #fff !important;
  box-shadow: 0 4px 20px rgba(13, 148, 136, 0.35);
}

[data-theme="dark"] .btn--primary {
  color: #042f2e !important;
  box-shadow: 0 4px 24px rgba(45, 212, 191, 0.25);
}

.btn--primary:hover {
  filter: brightness(1.06);
}

.btn--secondary {
  background: var(--bg-elevated);
  color: var(--text) !important;
  border-color: var(--border);
  box-shadow: var(--shadow);
}

.btn--secondary:hover {
  border-color: var(--accent);
  background: var(--accent-muted);
}

.btn--ghost {
  background: transparent;
  color: var(--text) !important;
  border-color: var(--border);
}

.btn--ghost:hover {
  background: var(--accent-muted);
  border-color: var(--accent);
}

.btn--sm {
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
}

.btn--lg {
  padding: 0.85rem 1.5rem;
  font-size: 1.05rem;
}

@media (max-width: 540px) {
  .header__actions .btn--sm {
    display: none;
  }
  .lang-select {
    max-width: 6.75rem;
    padding-left: 0.4rem;
    padding-right: 1.35rem;
  }
}

/* —— Hero —— */
.hero {
  display: grid;
  gap: 2.5rem;
  align-items: center;
  padding: 2rem 0 3rem;
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 1fr minmax(280px, 38vw);
    gap: clamp(2rem, 4vw, 3.5rem);
    padding: 3rem 0 4rem;
    align-items: start;
  }
}

.eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin: 0 0 0.75rem;
}

.hero__title {
  margin: 0 0 1rem;
  font-size: clamp(1.85rem, 4.2vw, 2.65rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.hero__lead {
  margin: 0;
  color: var(--text-secondary);
  max-width: 40rem;
}

.hero__lead + .hero__lead {
  margin-top: 1rem;
}

.hero__lead strong {
  color: var(--text);
  font-weight: 600;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.75rem;
}

.social {
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  font-size: 0.92rem;
  font-weight: 600;
}

.social a {
  text-decoration: none;
}

.social a:hover {
  text-decoration: underline;
}

.hero__figure {
  margin: 0;
  justify-self: center;
  width: 100%;
  max-width: min(420px, 100%);
}

@media (min-width: 900px) {
  .hero__figure {
    justify-self: end;
    max-width: min(440px, 38vw);
    position: sticky;
    top: calc(var(--header-h) + 1rem);
  }
}

.hero__photo-wrap {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  aspect-ratio: 1;
  isolation: isolate;
}

.hero__photo {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: cover;
  object-position: center 22%;
  display: block;
}

.hero__meta {
  margin: 1rem 0 0;
}

.hero__meta-grid {
  margin: 0;
  padding: 0.85rem 1rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem 1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

@media (max-width: 640px) {
  .hero__meta-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
}

.hero__meta-item {
  margin: 0;
  min-width: 0;
}

.hero__meta-term {
  margin: 0 0 0.15rem;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
}

.hero__meta-value {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
}

/* —— Sections —— */
.section {
  padding: 3rem 0;
  border-top: 1px solid var(--border);
}

.section__title {
  margin: 0 0 1rem;
  font-size: clamp(1.35rem, 2.5vw, 1.65rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.section__lede {
  margin: -0.5rem 0 1.5rem;
  color: var(--text-secondary);
  max-width: 42rem;
}

.prose p {
  margin: 0 0 1rem;
  color: var(--text-secondary);
  max-width: 42rem;
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose strong {
  color: var(--text);
  font-weight: 600;
}

/* Jobs */
.jobs {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.job {
  padding: 1.35rem 1.5rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.job__meta {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.15rem 1rem;
  align-items: start;
}

.job__role {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  grid-column: 1;
  grid-row: 1;
}

.job__badge {
  grid-column: 2;
  grid-row: 1;
  justify-self: end;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: var(--accent-muted);
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}

.job__org {
  font-weight: 600;
  color: var(--accent);
  grid-column: 1 / -1;
}

.job__dates {
  font-size: 0.9rem;
  color: var(--text-secondary);
  grid-column: 1 / -1;
}

.job__bullets {
  margin: 1rem 0 0;
  padding-left: 1.15rem;
  color: var(--text-secondary);
  font-size: 0.98rem;
}

.job__bullets li {
  margin-bottom: 0.35rem;
}

.job__bullets strong {
  color: var(--text);
}

/* Projects */
.projects {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 1rem;
}

@media (min-width: 720px) {
  .projects {
    grid-template-columns: repeat(2, 1fr);
  }
}

.project {
  padding: 1.35rem;
  border-radius: var(--radius-lg);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.project:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
  box-shadow: var(--shadow-md);
}

.project__name {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
}

.project__desc {
  margin: 0 0 0.85rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.tags {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.tags li {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: var(--accent-muted);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.tags--block {
  flex-direction: column;
  align-items: flex-start;
}

/* Skills */
.skill-groups {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .skill-groups {
    grid-template-columns: repeat(2, 1fr);
  }
}

.skill-group__label {
  margin: 0 0 0.6rem;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-secondary);
}

.section--two {
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .section--two {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }
}

.edu {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.edu li {
  padding: 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
}

.edu__degree {
  display: block;
  font-weight: 700;
}

.edu__school {
  display: block;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.edu__year {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
}

/* Contact */
.section--contact {
  border-bottom: 1px solid var(--border);
  padding-bottom: 4rem;
}

.contact-card {
  padding: 2.25rem 1.75rem;
  border-radius: calc(var(--radius-lg) + 4px);
  background: linear-gradient(145deg, var(--accent-muted), transparent 55%);
  border: 1px solid var(--border);
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
}

.contact-card__title {
  margin: 0 0 0.5rem;
  font-size: 1.5rem;
  font-weight: 700;
}

.contact-card__text {
  margin: 0 0 1.25rem;
  color: var(--text-secondary);
}

.contact-card__fine {
  margin: 1.25rem 0 0;
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.contact-card__fine a {
  font-weight: 600;
}

/* Footer */
.footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
  margin-top: -1px;
}

.footer__inner {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  text-align: center;
}

@media (min-width: 640px) {
  .footer__inner {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer__copy {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

/* —— Motion (respects prefers-reduced-motion via body.motion-reduce) —— */
@media (prefers-reduced-motion: no-preference) {
  body.motion-ok .hero--motion .hero__anim:not(.hero__anim--fig) {
    opacity: 0;
    animation: hero-rise 0.78s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  }

  body.motion-ok .hero--motion .hero__anim--1 {
    animation-delay: 0.04s;
  }
  body.motion-ok .hero--motion .hero__anim--2 {
    animation-delay: 0.1s;
  }
  body.motion-ok .hero--motion .hero__anim--3 {
    animation-delay: 0.16s;
  }
  body.motion-ok .hero--motion .hero__anim--4 {
    animation-delay: 0.22s;
  }
  body.motion-ok .hero--motion .hero__anim--5 {
    animation-delay: 0.28s;
  }
  body.motion-ok .hero--motion .hero__anim--6 {
    animation-delay: 0.34s;
  }

  body.motion-ok .hero--motion .hero__anim--fig {
    opacity: 0;
    animation: hero-fig-in 0.95s cubic-bezier(0.22, 1, 0.36, 1) 0.12s forwards;
  }

  @keyframes hero-rise {
    from {
      opacity: 0;
      transform: translateY(1.125rem);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  @keyframes hero-fig-in {
    from {
      opacity: 0;
      transform: translateY(0.65rem) scale(0.97);
    }
    to {
      opacity: 1;
      transform: translateY(0) scale(1);
    }
  }

  body.motion-ok .reveal {
    opacity: 0;
    transform: translateY(1.65rem);
    transition:
      opacity 0.72s cubic-bezier(0.22, 1, 0.36, 1),
      transform 0.72s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: var(--reveal-delay, 0s);
    will-change: opacity, transform;
  }

  body.motion-ok .reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
    will-change: auto;
  }

  body.motion-ok .project {
    transition:
      border-color 0.2s ease,
      box-shadow 0.22s ease,
      transform 0.22s ease;
  }

  body.motion-ok .project:hover {
    transform: translateY(-2px);
  }
}

body.motion-reduce .hero__anim,
body.motion-reduce .hero__anim--fig {
  opacity: 1 !important;
  animation: none !important;
  transform: none !important;
}

body.motion-reduce .reveal {
  opacity: 1;
  transform: none;
  transition: none;
}

/* —— Scroll to top —— */
.scroll-top {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 90;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-elevated) 92%, var(--accent-muted));
  color: var(--accent);
  box-shadow: var(--shadow-md);
  cursor: pointer;
  font-size: 1.15rem;
  line-height: 1;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease,
    opacity 0.25s ease;
}

.scroll-top:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border));
  color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.scroll-top:active {
  transform: translateY(0);
}

.scroll-top__icon {
  display: block;
  font-weight: 700;
  margin-top: -0.1em;
}

.scroll-top[hidden] {
  display: none !important;
}

.scroll-top:not([hidden]) {
  animation: scroll-top-in 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@media (prefers-reduced-motion: reduce) {
  .scroll-top:not([hidden]) {
    animation: none;
  }
}

@keyframes scroll-top-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media print {
  .scroll-top {
    display: none !important;
  }

  .header__actions,
  .lang-select,
  .theme-toggle,
  .menu-toggle,
  .skip-link {
    display: none !important;
  }
  .nav {
    display: none !important;
  }
  body {
    background: #fff;
    color: #000;
  }
  a {
    color: #000;
    text-decoration: underline;
  }
}
