/* Taban Studio — taban.studio */

@font-face {
  font-family: 'Clash Display';
  src: url('assets/fonts/ClashDisplay-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Clash Display';
  src: url('assets/fonts/ClashDisplay-Semibold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --ground: #FDFCF9;
  --ink: #1A1917;
  --ink-soft: #6E6A63;
  --sun: #E8A020;
  --sun-deep: #9A650A;
  --sun-wash: #FBF0DC;
  --line: #E9E5DD;
  --card: #FFFFFF;

  --display: 'Clash Display', ui-sans-serif, system-ui, sans-serif;
  --body: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

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

body, h1, h2, p, ul, li, figure { margin: 0; padding: 0; }

ul { list-style: none; }

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

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

body {
  background: var(--ground);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection {
  background: rgba(232, 160, 32, 0.24);
}

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

/* --- Signature: warm light falling across the top of the page --- */

.sunrise {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: min(75vh, 720px);
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(105% 76% at 38% -10%, rgba(232, 160, 32, 0.26) 0%, rgba(232, 160, 32, 0.08) 36%, rgba(232, 160, 32, 0) 70%),
    radial-gradient(60% 44% at 88% 4%, rgba(232, 160, 32, 0.10) 0%, rgba(232, 160, 32, 0) 62%);
}

.shell {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
  padding: clamp(4rem, 13vh, 7.5rem) 1.5rem 3rem;
}

/* --- Hero --- */

.wordmark {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(4.5rem, 18vw, 8.5rem);
  line-height: 0.86;
  letter-spacing: -0.045em;
}

.etymology {
  margin-top: 0.875rem;
  font-size: 0.9375rem;
  color: var(--ink-soft);
}

.etymology [lang='fa'] {
  font-size: 1.1em;
  color: var(--ink);
}

.etymology .dash {
  padding: 0 0.15em;
  color: var(--sun);
}

.lede {
  margin-top: 2.25rem;
  max-width: 46ch;
  font-size: clamp(1.0625rem, 1.5vw, 1.1875rem);
  line-height: 1.6;
}

/* --- Sections --- */

.section {
  margin-top: clamp(4rem, 10vh, 6rem);
}

.section-label {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-family: var(--display);
  font-weight: 500;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--ink-soft);
}

.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* --- Apps --- */

.app-grid {
  margin-top: 1.75rem;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.app-link {
  display: flex;
  align-items: flex-start;
  gap: 1.125rem;
  height: 100%;
  padding: 1.5rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  color: inherit;
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.app-link:hover {
  border-color: rgba(232, 160, 32, 0.55);
  transform: translateY(-2px);
  box-shadow: 0 10px 26px -14px rgba(26, 25, 23, 0.25);
}

.app-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--sun-wash);
  color: var(--sun-deep);
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.25rem;
}

.app-body {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.app-name {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}

.app-desc {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

.app-platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-top: 0.25rem;
}

.badge {
  padding: 0.1875rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* --- About --- */

.about {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  margin-top: 1.75rem;
}

.avatar {
  flex: none;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: var(--line);
}

.about-name {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.125rem;
}

.about-bio {
  margin-top: 0.5rem;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--ink-soft);
}

.social {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-top: 1.125rem;
}

.social a {
  font-size: 0.9375rem;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--sun);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 5px;
  transition: text-decoration-thickness 0.15s ease;
}

.social a:hover {
  text-decoration-thickness: 3px;
}

/* --- Footer --- */

.footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: clamp(4rem, 10vh, 6rem);
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.email {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}

.reveal,
.copy {
  font-family: inherit;
  font-size: 0.875rem;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.reveal:hover,
.copy:hover {
  border-color: rgba(232, 160, 32, 0.6);
  background: #FFF9EE;
}

.copy {
  padding: 0.375rem 0.75rem;
  font-size: 0.8125rem;
  color: var(--ink-soft);
}

.email-address {
  font-size: 0.9375rem;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--sun);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 5px;
}

.noscript-note,
.copyright {
  font-size: 0.8125rem;
  color: var(--ink-soft);
}

/* --- Motion: one orchestrated entrance, nothing else --- */

@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

.hero > * {
  animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.3, 1) both;
}

.hero .etymology { animation-delay: 0.09s; }
.hero .lede      { animation-delay: 0.18s; }

.sunrise {
  animation: fade 1.4s ease-out both;
}

@keyframes fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* --- Narrow screens --- */

@media (max-width: 30rem) {
  .about {
    flex-direction: column;
    gap: 1.125rem;
  }

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

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .app-link:hover {
    transform: none;
  }
}
