/* Global Advisor Thinker — Static Site (v1)
   Light editorial default with optional dark mode.
*/

:root{
  --bg:#ffffff;
  --surface:#f5f7fb;
  --surface-2:#eef3fb;
  --text:#0b1220;
  --muted:#52627a;
  --border:#e3eaf5;
  --accent:#2f7cff;
  --accent-2:#00a6a6;
  --shadow:0 10px 28px rgba(10, 20, 40, .08);
  --radius:16px;
  --radius-2:12px;
  --max:1120px;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  --sans: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* Dark mode overrides */
html.theme-dark{
  --bg:#0b1220;
  --surface:#0f1a2e;
  --surface-2:#101f38;
  --text:#e9edf6;
  --muted:#b6c2db;
  --border:rgba(255,255,255,.12);
  --shadow:0 16px 36px rgba(0,0,0,.35);
}

*{box-sizing:border-box;}
html,body{height:100%;}
body{
  margin:0;
  font-family:var(--sans);
  color:var(--text);
  background:var(--bg);
  line-height:1.6;
}

a{color:var(--accent); text-decoration:none;}
a:hover{text-decoration:underline;}

.container{max-width:var(--max); margin:0 auto; padding:0 16px;}

/* Header */
.site-header{
  position:sticky;
  top:0;
  z-index:50;
  background:color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter:saturate(180%) blur(10px);
  border-bottom:1px solid var(--border);
}
.header-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:12px 0;
}
.brand{
  display:flex;
  align-items:center;
  gap:10px;
  min-width:220px;
}
.brand img{width:30px; height:30px;}
.brand-title{
  display:flex;
  flex-direction:column;
  line-height:1.1;
}
.brand-title strong{font-weight:800; letter-spacing:.2px; color:var(--text);}
.brand-title span{font-size:12px; color:var(--muted);}

.nav{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  justify-content:flex-end;
}
.nav a{
  color:var(--text);
  padding:8px 10px;
  border-radius:10px;
  border:1px solid transparent;
  font-weight:650;
  font-size:14px;
}
.nav a:hover{border-color:var(--border); text-decoration:none;}
.nav a.active{border-color:var(--border); background:color-mix(in srgb, var(--surface) 72%, transparent);}

.header-actions{display:flex; gap:10px; align-items:center;}
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--border);
  background:transparent;
  color:var(--text);
  font-weight:700;
  cursor:pointer;
  text-decoration:none;
}
.btn:hover{text-decoration:none; border-color:color-mix(in srgb, var(--border) 60%, var(--accent));}
.btn.primary{background:var(--accent); color:#071224; border-color:transparent;}
.btn.primary:hover{filter:brightness(1.03);}
.btn.small{padding:8px 10px; border-radius:10px; font-size:13px;}

/* Layout blocks */
main{padding:34px 0 56px 0;}
.section{padding:26px 0; border-top:1px solid var(--border);}
.section:first-child{border-top:none; padding-top:10px;}

.kicker{color:var(--muted); font-size:13px; letter-spacing:.08em; text-transform:uppercase; margin:0 0 10px 0;}
.h1{font-size:40px; line-height:1.12; margin:0 0 12px 0; font-weight:820; letter-spacing:-.02em;}
.lead{color:var(--muted); font-size:18px; margin:0; max-width:960px;}

@media(max-width:900px){.h1{font-size:34px;}}
@media(max-width:640px){.h1{font-size:28px;} .brand{min-width:auto;}}

.hero{
  padding:14px 0 10px 0;
}
.hero-grid{
  display:grid;
  grid-template-columns: 1.15fr .85fr;
  gap:14px;
  align-items:start;
}
@media(max-width:900px){.hero-grid{grid-template-columns:1fr;}}

.panel{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:16px;
  box-shadow:var(--shadow);
}

.search-row{display:flex; gap:10px; flex-wrap:wrap; margin-top:14px;}
.search-input{
  flex:1 1 340px;
  min-width:260px;
  padding:12px 14px;
  border-radius:14px;
  border:1px solid var(--border);
  background:color-mix(in srgb, var(--surface) 65%, transparent);
  color:var(--text);
  outline:none;
}
.search-input::placeholder{color:color-mix(in srgb, var(--muted) 78%, transparent);}

.meta-line{margin-top:10px; color:var(--muted); font-size:13px;}
.pill{display:inline-block; padding:6px 10px; border:1px solid var(--border); border-radius:999px; color:var(--muted); font-size:13px;}

.grid{display:grid; gap:14px;}
.grid.cols3{grid-template-columns:repeat(3,1fr);} 
.grid.cols2{grid-template-columns:repeat(2,1fr);} 
@media(max-width:980px){.grid.cols3{grid-template-columns:repeat(2,1fr);} }
@media(max-width:640px){.grid.cols3,.grid.cols2{grid-template-columns:1fr;} }

.card{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:16px;
}
.card.alt{background:var(--surface-2);}
.card h3{margin:0 0 8px 0; font-size:16px; letter-spacing:.1px;}
.card p{margin:0; color:var(--muted);} 

.tags{display:flex; gap:8px; flex-wrap:wrap; margin-top:10px;}
.tag{font-size:12px; padding:4px 8px; border:1px solid var(--border); border-radius:999px; color:var(--muted);} 

.list{display:flex; flex-direction:column; gap:10px;}
.item{
  padding:14px 16px;
  border:1px solid var(--border);
  border-radius:var(--radius);
  background:color-mix(in srgb, var(--surface) 65%, transparent);
}
.item-top{display:flex; gap:10px; flex-wrap:wrap; align-items:center; justify-content:space-between;}
.item-title{margin:0; font-weight:800; font-size:15px;}
.item-date{color:var(--muted); font-size:13px;}
.item-desc{margin:8px 0 0 0; color:var(--muted);}

/* Filters */
.filters{display:flex; gap:10px; flex-wrap:wrap; align-items:center; margin:10px 0 0 0;}
.select{
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--border);
  background:color-mix(in srgb, var(--surface) 65%, transparent);
  color:var(--text);
  min-width:190px;
}

/* Work pages */
.breadcrumb{font-size:13px; color:var(--muted); margin:0 0 10px 0;}
.work-meta{display:flex; gap:8px; flex-wrap:wrap; margin:10px 0 0 0;}
.work-meta .tag{font-family:var(--mono);}
.work-body{margin-top:14px;}
.work-body h2{margin-top:22px;}
.work-body code, .work-body pre{font-family:var(--mono);}
.work-body pre{padding:12px; background:color-mix(in srgb, var(--surface-2) 72%, transparent); border:1px solid var(--border); border-radius:12px; overflow:auto;}

/* Footer */
.site-footer{
  border-top:1px solid var(--border);
  padding:22px 0 34px 0;
  color:var(--muted);
}
.footer-grid{display:grid; grid-template-columns:1.2fr .8fr; gap:14px;}
@media(max-width:900px){.footer-grid{grid-template-columns:1fr;}}
.footer-links{display:flex; gap:10px; flex-wrap:wrap;}
.footer-links a{color:var(--muted);}
.footer-links a:hover{color:var(--text); text-decoration:none;}
.small{font-size:13px;}
