/* Original Abtin theme, with a consistent native-size layout. */
:root {
  --smoky-black: hsl(65, 41%, 93%);
  --eerie-black-2: #deddd2; /* Warm stone panels on the original cream background. */
  --jet: #a14e46;
  --divider: #b98980;
  --control-border: #a14e46;
  --error: #963c32;
  --white-2: hsl(48, 12%, 25%);
  --light-gray: #252724;
  --light-gray-70: #d6d6d6;
  --orange-yellow-crayola: hsl(45, 100%, 72%);
  --vegas-gold: #705018;
  --text-gradient-yellow: linear-gradient(90deg,#ffdb70,#ffbb5c);
  --shadow-1: 0 10px 28px #24251e1a;
  --shadow-5: var(--shadow-1);
}
html { scrollbar-gutter: stable; }
body { font-size: 15px; line-height: 1.7; }
main { --profile-width: clamp(220px, 23vw, 286px); --column-gap: 26px; display: grid; grid-template-columns: var(--profile-width) minmax(0, calc((100% - var(--profile-width) - var(--column-gap)) * .9)); justify-content: center; align-items: start; gap: var(--column-gap); max-width: 1250px; min-width: 0; margin: 48px auto; padding: 0 24px; }
.sidebar, article { width: 100%; margin: 0; border: 1px solid var(--jet); border-radius: 20px; box-shadow: var(--shadow-1); }
.sidebar { position: sticky; top: 32px; height: auto; max-height: none; padding: 36px clamp(18px, 2vw, 24px) 28px; overflow: hidden; }
.sidebar-info { flex-direction: column; gap: 22px; }
.avatar-box { width: 100%; height: auto; aspect-ratio: 1; max-width: 234px; border-radius: 24px; flex-shrink: 0; }
.avatar-box img { width: 100%; height: 100%; object-fit: cover; border: 1px solid var(--jet); border-radius: inherit; }
.info-content { width: 100%; min-width: 0; }
.info-content .name { font-size: 23px; font-weight: 500; line-height: 1.35; letter-spacing: -.5px; white-space: normal; text-align: center; margin-bottom: 14px; }
.info-content .title { width: fit-content; max-width: 100%; margin: auto; padding: 7px 12px; background: #2b2b2c; color: #fff; border: 0; border-radius: 8px; font-size: 12px; font-weight: 400; text-align: center; line-height: 1.7; }
.break { display: block; }
.sidebar [data-sidebar-btn] { display: none; }
.separator, .separator:last-of-type { margin: 24px 0 20px; background: var(--jet); }
.social-list { justify-content: center; gap: 16px; padding: 0; }
.social-link { display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 8px; }
.social-item .social-link { color: #30312d; }
.social-link ion-icon { font-size: 28px !important; }
.social-link:hover { background: #0000000b; }
.main-content { position: relative; width: 100%; min-width: 0; margin: 0; background: hsl(55.000000, 15.384615%, 88.941176%); border: 1px solid var(--jet); border-radius: 20px; box-shadow: var(--shadow-1); scroll-margin-top: 16px; }
article { padding: 28px 32px 30px; min-height: 0; border: 0; box-shadow: none; background: transparent; }
article.active { animation: fade .18s ease; }
/* A wrapping header reserves real space for both title and attached navigation. */
.panel-header { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.navbar { position: relative; inset: auto; flex: 0 1 auto; width: max-content; max-width: calc(100% + 2px); margin: -1px -1px 0 auto; padding: 0 14px; background: #41413e; border: 1px solid var(--jet); border-radius: 0 20px 0 20px; box-shadow: none; backdrop-filter: none; z-index: 5; }
.navbar-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; padding: 0; }
.navbar-link { padding: 18px 8px; color: #deded8; font-size: 13px; font-weight: 500; line-height: 1.5; border-radius: 0; background: none; }
.navbar-link.active { color: var(--orange-yellow-crayola); }
.navbar-link:hover, .navbar-link:focus-visible { color: #fff0bd; }
.navbar-link::after { display: none; }
.h2 { font-size: 28px; line-height: 1.3; letter-spacing: -.6px; }
.h3 { font-size: 21px; line-height: 1.4; letter-spacing: -.25px; }
.panel-header .article-title { flex: 1 1 auto; width: auto; min-width: 0; padding-bottom: 15px; margin: 26px 0 0 32px; }
.article-title::after { width: 38px; height: 4px; background: var(--text-gradient-yellow); }
.about-text { max-width: 76ch; font-size: 15px !important; font-weight: 400; line-height: 1.85; margin-bottom: 32px; }
.about-text p { margin-bottom: 16px; }
.about-text p:last-child { margin-bottom: 0; }
.about-text a { font-weight: 500 !important; }
.news-section { margin: 0; }
.section-title { margin-bottom: 18px; }
.news-list { border-top: 1px solid var(--divider); }
.news-item { grid-template-columns: 78px minmax(0,1fr); gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--divider); }
.news-date { font-size: 13px; padding-top: 2px; }
.news-text { font-size: 14px; font-weight: 400; line-height: 1.6; }
.about .footer { position: static; margin: 28px 0 0 auto; padding: 0; font-size: 11px; color: #56584f; }
.timeline { margin-bottom: 34px; }
.timeline:last-child { margin-bottom: 0; }
.timeline .title-wrapper { gap: 14px; margin-bottom: 22px; }
.icon-box { width: 38px; height: 38px; flex-shrink: 0; border-radius: 10px; font-size: 20px; box-shadow: 0 4px 10px #00000012; }
.timeline-list { --timeline-indent: 52px; margin-left: var(--timeline-indent); font-size: 14px; }
.timeline-item { font-size: 14px !important; }
.timeline-item:not(:last-child) { margin-bottom: 24px; }
.timeline-item-title { font-size: 15px !important; font-weight: 600; line-height: 1.65; margin-bottom: 4px; }
.timeline-text, .research-bullets { font-size: 14px !important; font-weight: 400; line-height: 1.8; max-width: none; }
.timeline-list span { font-size: 13px; line-height: 1.8; margin-bottom: 6px; }
.timeline-list span a { font-size: 13px !important; font-weight: 500 !important; }
.timeline-item::after { width: 6px; height: 6px; left: calc(16px - var(--timeline-indent)); top: 9px; background: var(--text-gradient-yellow); box-shadow: 0 0 0 3px var(--jet); }
.timeline-item:not(:last-child)::before { left: calc(19px - var(--timeline-indent)); top: 12px; height: calc(100% + 24px); background: var(--jet); }
.resume[data-page=resume] .timeline .timeline-item:only-child::before { display: none; }
.research-bullets { padding-left: 18px; }
.research-bullets li { list-style: disc; }
.publication-section .timeline-list { margin: 0; }
.publication-item::before, .publication-item::after { display: none; }
.publication-item { padding-bottom: 24px; border-bottom: 1px solid var(--divider); }
.publication-item:last-child { padding-bottom: 0; border-bottom: 0; }
.publication-item .publication-title { color: hsl(193.043478, 89.147287%, 27.823529%) !important; font-size: 16px; line-height: 1.6; font-weight: 600 !important; margin-bottom: 8px !important; }
.publication-note { margin: 24px 0 0; font-size: 12px; }
.mapbox { height: 220px; border-radius: 14px; margin-bottom: 28px; }
.mapbox iframe { filter: grayscale(.65); }
.form-title { font-size: 20px; margin-bottom: 20px; }
.input-wrapper { grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 18px; }
.input-wrapper input:last-child { grid-column: 1/-1; }
.form-input { font-size: 14px; padding: 13px 15px; border: 1px solid var(--control-border); border-radius: 10px; background: #ffffff24; }
.form-input::placeholder { color: #5c5d53; font-weight: 400; }
textarea.form-input { height: 150px; max-height: none; margin-bottom: 20px; }
.form-btn { padding: 12px 20px; font-size: 14px; border-radius: 10px; box-shadow: 0 4px 12px #00000012; background: #41413e; border: 1px solid #41413e; color: #ffdb70 !important; }
.form-btn:disabled { opacity: .55; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
.social-link:hover { text-decoration: none; }
:focus-visible { outline: 2px solid #07617a; outline-offset: 4px; }
.navbar-link:focus-visible { outline-color: #ffdb70; outline-offset: -3px; }
.form-input:focus { border-color: #07617a; outline: 2px solid #07617a; outline-offset: 2px; }
@media (max-width: 1100px) {
 main { --column-gap: 22px; padding: 0 20px; }
 .sidebar { padding-top: 30px; padding-bottom: 24px; }
 .info-content .name { font-size: 21px; }
 article { padding: 26px 24px 28px; }
 .navbar { padding: 0 9px; }
 .navbar-list { gap: 4px; }
 .navbar-link { font-size: 13px; padding: 18px 7px; }
 .panel-header .article-title { margin-left: 24px; margin-top: 24px; }
 .h2 { font-size: 26px; }
}
@media (max-width: 899px) {
 main { display: block; max-width: 900px; margin: 28px auto; padding: 0 22px; }
 .sidebar { position: static; padding: 24px; margin-bottom: 26px; }
 .sidebar-info { flex-direction: row; gap: 24px; }
 .avatar-box { width: clamp(120px, 20vw, 180px); height: auto; min-width: 120px; border-radius: 18px; }
 .info-content .name { text-align: left; font-size: 24px; }
 .info-content .title { margin: 0; text-align: left; }
 .separator { display: none; }
 .social-list { justify-content: flex-start; margin-top: 18px; }
}
@media (max-width: 600px) {
 main { padding: 0 12px; margin: 14px auto 90px; }
 .sidebar { padding: 20px; margin-bottom: 20px; }
 .sidebar-info { gap: 16px; }
 .avatar-box { width: clamp(76px, 18vw, 108px); height: auto; min-width: 76px; border-radius: 16px; }
 .info-content .name { font-size: 20px; }
 .info-content .title { font-size: 11px; padding: 6px 9px; }
 article { padding: 25px 22px; }
 .panel-header .article-title { margin: 24px 22px 0; }
 .navbar { position: fixed; top: auto; bottom: 0; left: 0; right: 0; width: 100%; max-width: none; margin: 0; padding: 0 8px env(safe-area-inset-bottom); border-radius: 16px 16px 0 0; box-shadow: 0 -4px 18px #00000012; }
 .navbar-list { justify-content: space-around; gap: 0; }
 .navbar-link { font-size: 13px; padding: 18px 10px; }
 .timeline-list { --timeline-indent: 44px; }
 .news-item { grid-template-columns: 66px minmax(0,1fr); gap: 12px; }
 .input-wrapper { grid-template-columns: 1fr; }
 .form-btn { width: 100%; }
}
@media (max-width: 380px) {
 .info-content .name { font-size: 18px; }
 .sidebar { padding: 16px; }
 .news-item { grid-template-columns: 1fr; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
 *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Consistent light-surface contrast and compact publication metadata. */
::selection { background: #ffdb70; color: #252724; }
.resume[data-page="resume"] .education-details > div { line-height: 1.8; }
.publication-meta { font-size: 13px; line-height: 1.7; color: #575449; margin-top: 6px; }
.publication-meta a { display: inline; color: hsl(193.043478, 89.147287%, 27.823529%); font-weight: 500; }
.form-btn::before { display: none; }
.form-btn:hover, .form-btn:focus-visible { background: #30302e; }
.form-btn:disabled:hover { background: #41413e; }
.form-input:focus:invalid { border-color: var(--error); }
.form-status { margin-top: 14px; font-size: 14px; line-height: 1.6; color: #334b36; }
.form-status:empty { display: none; }
.form-status[data-state="error"] { color: var(--error); }
body::-webkit-scrollbar { width: 14px; }
body::-webkit-scrollbar-thumb { background: #8d8c81; border: 4px solid var(--smoky-black); border-radius: 10px; box-shadow: none; }
body::-webkit-scrollbar-thumb:hover { background: #6b6b61; }
body::-webkit-scrollbar-button { height: 0; }
@media (max-width: 600px) {
 .form-input { font-size: 16px; }
 main { margin-bottom: calc(90px + env(safe-area-inset-bottom)); }
}
