/* Author pages: hero, random story cards, topics. Uses the site's theme variables (light + dark). */
.au-wrap { max-width: 1120px; margin: 0 auto; padding: 8px 20px 56px; }
.au-wrap h2 { color: var(--heading); font-size: 1.5rem; font-weight: 800; line-height: 1.25; margin: 0 0 6px; }

/* ---------- hero ---------- */
.au-hero { position: relative; overflow: hidden; display: flex; gap: 36px; align-items: center; padding: 44px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 24px; box-shadow: 0 10px 40px var(--shadow); }
.au-hero::before { content: ""; position: absolute; inset: -40% -10% auto auto; width: 560px; height: 560px; pointer-events: none;
  background: radial-gradient(circle, rgba(168, 85, 247, .30), transparent 62%); }
.au-hero::after { content: ""; position: absolute; inset: auto auto -50% -10%; width: 420px; height: 420px; pointer-events: none;
  background: radial-gradient(circle, rgba(245, 158, 11, .14), transparent 65%); }
.au-hero > * { position: relative; z-index: 1; }
.au-ring { flex: 0 0 auto; padding: 5px; border-radius: 50%; background: conic-gradient(from 210deg, #a855f7, #7c3aed, #f59e0b, #a855f7); box-shadow: 0 12px 34px rgba(124, 58, 237, .35); }
.au-avatar { display: block; width: 148px; height: 148px; border-radius: 50%; object-fit: cover; object-position: 50% 20%; border: 4px solid var(--surface); background: var(--surface); }
.au-eyebrow { color: var(--pill-fg); font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; margin: 0 0 8px; }
.au-hero h1 { color: var(--heading); font-size: clamp(2rem, 4.6vw, 3rem); font-weight: 800; line-height: 1.1; margin: 0 0 14px; letter-spacing: -.02em; }
.au-bio { color: var(--text); font-size: 1.05rem; line-height: 1.65; max-width: 62ch; margin: 0 0 20px; }
.au-stats { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 22px; padding: 0; }
.au-stats li { display: flex; flex-direction: column; min-width: 92px; padding: 10px 16px; border-radius: 14px; background: var(--pill-bg); border: 1px solid var(--pill-edge); }
.au-stats strong { color: var(--heading); font-size: 1.35rem; font-weight: 800; line-height: 1.1; }
.au-stats li.is-link { padding: 0; }
.au-stats li a { display: flex; flex-direction: column; min-width: 92px; padding: 10px 16px; border-radius: 14px; text-decoration: none; color: inherit; transition: transform .2s ease, background .2s ease, box-shadow .2s ease; }
.au-stats li.is-link:hover, .au-stats li.is-link:focus-within { border-color: #a855f7; background: rgba(168, 85, 247, .22); box-shadow: 0 8px 22px rgba(124, 58, 237, .28); transform: translateY(-2px); }
.au-stats li.is-link span::after { content: " \2192"; }
.au-stats span { color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .08em; margin-top: 2px; }
.au-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.au-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; font-size: .9rem; font-weight: 600; text-decoration: none;
  color: var(--heading); background: transparent; border: 1px solid var(--border); cursor: pointer; font-family: inherit; transition: transform .2s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease; }
.au-btn:hover { transform: translateY(-2px); border-color: #a855f7; box-shadow: 0 8px 22px rgba(124, 58, 237, .25); }
.au-btn.is-primary { color: #fff; border-color: transparent; background: linear-gradient(135deg, #a855f7, #7c3aed); }
.au-btn svg { width: 16px; height: 16px; flex: 0 0 auto; }

/* ---------- sections ---------- */
.au-section { margin-top: 56px; }
.au-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.au-head p { color: var(--muted); margin: 0; font-size: .95rem; }
.au-shuffle svg { transition: transform .5s cubic-bezier(.34, 1.56, .64, 1); }
.au-shuffle:hover svg { transform: rotate(180deg); }

/* ---------- story cards ---------- */
.au-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.au-card { display: flex; flex-direction: column; overflow: hidden; text-decoration: none; color: inherit; background: var(--surface);
  border: 1px solid var(--border); border-radius: 18px; transition: transform .28s ease, border-color .28s ease, box-shadow .28s ease; }
.au-card:hover, .au-card:focus-visible { transform: translateY(-5px); border-color: #a855f7; box-shadow: 0 16px 36px rgba(124, 58, 237, .22); outline: none; }
.au-thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, rgba(124, 58, 237, .45), rgba(245, 158, 11, .25)); }
.au-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.au-card:hover .au-thumb img { transform: scale(1.06); }
.au-thumb::after { content: ""; position: absolute; inset: auto 0 0 0; height: 45%; background: linear-gradient(to top, rgba(0, 0, 0, .55), transparent); pointer-events: none; }
.au-tag, .au-kind { position: absolute; z-index: 2; top: 12px; padding: 4px 11px; border-radius: 999px; font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.au-tag { left: 12px; color: #fff; background: linear-gradient(135deg, #a855f7, #7c3aed); }
.au-kind { right: 12px; color: #fff; background: rgba(0, 0, 0, .55); backdrop-filter: blur(6px); }
.au-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 20px; flex: 1; }
.au-body time { color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .08em; }
.au-body h3 { color: var(--heading); font-size: 1.08rem; font-weight: 700; line-height: 1.35; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.au-body p { color: var(--muted); font-size: .9rem; line-height: 1.55; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.au-read { margin-top: auto; padding-top: 6px; color: var(--link); font-size: .88rem; font-weight: 600; }
.au-card:hover .au-read { color: var(--link-hover); }
/* first card is the feature: full row, image left */
.au-card:first-child { grid-column: 1 / -1; flex-direction: row; }
.au-card:first-child .au-thumb { flex: 0 0 52%; aspect-ratio: auto; min-height: 280px; }
.au-card:first-child .au-body { justify-content: center; padding: 30px 34px; gap: 12px; }
.au-card:first-child h3 { font-size: 1.65rem; line-height: 1.25; -webkit-line-clamp: 4; }
.au-card:first-child p { font-size: 1rem; -webkit-line-clamp: 4; }
.au-more { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 28px; }
.au-empty { grid-column: 1 / -1; padding: 36px; text-align: center; color: var(--muted); border: 1px dashed var(--border); border-radius: 16px; }

@media (prefers-reduced-motion: no-preference) {
  .au-grid.is-in .au-card { animation: au-up .5s cubic-bezier(.2, .7, .2, 1) backwards; animation-delay: calc(var(--i, 0) * 55ms); }
  @keyframes au-up { from { opacity: 0; transform: translateY(18px); } }
}

/* ---------- topics + coverage + contact ---------- */
.au-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
a.au-chip { text-decoration: none; cursor: pointer; transition: transform .2s ease, background .2s ease, box-shadow .2s ease, border-color .2s ease; }
a.au-chip:hover, a.au-chip:focus-visible { transform: translateY(-2px); border-color: #a855f7; background: linear-gradient(135deg, #a855f7, #7c3aed); color: #fff; box-shadow: 0 8px 20px rgba(124, 58, 237, .35); outline: none; }
a.au-chip:hover b, a.au-chip:hover em { color: rgba(255, 255, 255, .8); }
.au-chip em { font-style: normal; font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.au-chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; font-size: .88rem; font-weight: 600; color: var(--pill-fg); background: var(--pill-bg); border: 1px solid var(--pill-edge); }
.au-chip b { color: var(--muted); font-weight: 600; font-size: .78rem; }
.au-cover { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 18px; }
.au-cover > div { padding: 24px; border-radius: 18px; background: var(--surface); border: 1px solid var(--border); }
.au-cover h3 { color: var(--heading); font-size: 1.05rem; font-weight: 700; margin: 0 0 8px; }
.au-cover p { color: var(--muted); font-size: .92rem; line-height: 1.6; margin: 0; }
.au-cover a, .au-contact a { color: var(--link); }
.au-contact { padding: 30px 34px; border-radius: 20px; background: var(--surface); border: 1px solid var(--border); }
.au-contact p { color: var(--text); line-height: 1.65; margin: 8px 0 0; max-width: 70ch; }

@media (max-width: 900px) {
  .au-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .au-cover { grid-template-columns: 1fr; }
  .au-card:first-child { flex-direction: column; }
  .au-card:first-child .au-thumb { flex: none; aspect-ratio: 16 / 9; min-height: 0; }
  .au-card:first-child .au-body { padding: 22px; }
  .au-card:first-child h3 { font-size: 1.3rem; }
}
@media (max-width: 640px) {
  .au-wrap { padding: 4px 14px 40px; }
  .au-hero { flex-direction: column; align-items: flex-start; gap: 22px; padding: 28px 22px; border-radius: 20px; }
  .au-avatar { width: 112px; height: 112px; }
  .au-grid { grid-template-columns: 1fr; gap: 16px; }
  .au-section { margin-top: 42px; }
}

/* line the "Back to Home" pill up with the wider author layout */
body > nav { max-width: 1120px; padding: 0 20px; }
@media (max-width: 640px) { body > nav { padding: 0 14px; } }
