@import url("https://fonts.googleapis.com/css2?family=Sora:wght@500;600;700;800&family=Manrope:wght@400;500;600;700&display=swap");

:root{
  --bg: #f7f9fc;
  --ink: #102434;
  --muted: #4a6070;
  --surface: rgba(255, 255, 255, .86);
  --surface-strong: rgba(255, 255, 255, .94);
  --surface-soft: #f1f7fb;
  --line: #d2dde7;
  --line-strong: #b9cad8;
  --shadow-soft: 0 14px 36px rgba(20, 46, 67, .10);
  --shadow-deep: 0 28px 64px rgba(20, 46, 67, .13);
  --focus: 0 0 0 4px rgba(13, 113, 201, .24);

  --accent-1: #0ea5e9;
  --accent-2: #14b8a6;
  --accent-3: #f97316;
  --accent-4: #f4b400;

  --link: #055593;
  --link-hover: #013b69;

  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 26px;
}

*{ box-sizing: border-box; }
html, body{ height: 100%; }
[hidden]{ display: none !important; }

body{
  margin: 0;
  color: var(--ink);
  font-family: "Manrope", "Segoe UI", Arial, sans-serif;
  line-height: 1.68;
  background:
    radial-gradient(1200px 680px at -10% -20%, rgba(14,165,233,.20), transparent 62%),
    radial-gradient(1080px 720px at 110% -20%, rgba(20,184,166,.18), transparent 58%),
    radial-gradient(880px 540px at 50% 120%, rgba(249,115,22,.13), transparent 62%),
    linear-gradient(180deg, #f7f9fc 0%, #fdfefe 52%, #f8fcff 100%);
  position: relative;
}

body::before{
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(15, 35, 52, .05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 35, 52, .05) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: radial-gradient(ellipse at center, #000 58%, transparent 100%);
  opacity: .22;
  z-index: -1;
}

h1, h2, h3, h4{
  margin-top: 0;
  font-family: "Sora", "Trebuchet MS", sans-serif;
  line-height: 1.2;
  letter-spacing: .01em;
  color: #0f2f44;
}

a{
  color: var(--link);
  text-underline-offset: 3px;
  text-decoration-color: rgba(5, 85, 147, .32);
}

a:hover{
  color: var(--link-hover);
  text-decoration-color: rgba(1, 59, 105, .58);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible{
  outline: none;
  box-shadow: var(--focus);
}

.skip-link{
  position: absolute;
  left: -9999px;
  top: 10px;
  z-index: 999;
  color: #fff;
  background: #032338;
  border-radius: var(--radius-sm);
  padding: 11px 13px;
  border: 1px solid #7ec9ff;
}

.skip-link:focus{
  left: 12px;
}

.site-shell{
  max-width: 1160px;
  margin: 0 auto;
  padding: 26px 16px 34px;
}

.site-header{
  position: relative;
  overflow: hidden;
  padding: 22px 22px 18px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(180, 198, 214, .88);
  background:
    linear-gradient(120deg, rgba(255,255,255,.96), rgba(243,250,255,.92) 45%, rgba(255,250,245,.9));
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-deep);
}

.site-header::before{
  content: "";
  position: absolute;
  width: 360px;
  height: 360px;
  top: -180px;
  right: -110px;
  border-radius: 50%;
  background: radial-gradient(circle at center, rgba(14,165,233,.35), rgba(14,165,233,0));
  pointer-events: none;
}

.site-header::after{
  content: "";
  position: absolute;
  width: 260px;
  height: 260px;
  left: -90px;
  bottom: -130px;
  border-radius: 50%;
  background: radial-gradient(circle at center, rgba(249,115,22,.22), rgba(249,115,22,0));
  pointer-events: none;
}

.brand-row{
  display: grid;
  align-items: center;
  grid-template-columns: 94px 1fr auto;
  gap: 12px;
  position: relative;
  z-index: 2;
}

.brand-logo{
  width: 86px;
  height: 86px;
  border-radius: 24px;
  border: 1px solid rgba(154, 183, 207, .8);
  background: #fff;
  object-fit: contain;
  padding: 8px;
  box-shadow: 0 14px 28px rgba(12, 39, 59, .16);
}

.brand-name{
  margin: 0;
  font-size: clamp(1.6rem, 3.2vw, 2rem);
  font-weight: 800;
  color: #0b3045;
}

.brand-tagline{
  margin: 6px 0 0;
  color: #3f5d71;
  font-size: 14px;
  font-weight: 600;
}

.clock-chip{
  justify-self: end;
  min-width: 190px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(178, 196, 212, .86);
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow-soft);
  position: relative;
  z-index: 2;
}

.clock-label{
  display: block;
  font-size: 11px;
  color: #50697a;
  font-weight: 700;
}

.clock-chip time{
  display: block;
  margin-top: 3px;
  font-size: 14px;
  font-weight: 700;
  color: #12344a;
  font-variant-numeric: tabular-nums;
}

.top-nav{
  position: relative;
  z-index: 2;
  margin-top: 16px;
  padding: 8px;
  border-radius: 14px;
  border: 1px solid rgba(183, 200, 214, .76);
  background: rgba(255,255,255,.58);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.nav-link{
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 13px;
  border-radius: 10px;
  border: 1px solid rgba(182, 199, 214, .7);
  background: rgba(255,255,255,.86);
  color: #17384d;
  font-size: 14px;
  font-weight: 700;
  transition: transform .16s ease, border-color .16s ease, background-color .16s ease, box-shadow .16s ease;
}

.nav-link:hover{
  transform: translateY(-1px);
  border-color: #88b4d7;
  box-shadow: 0 10px 22px rgba(20, 53, 77, .12);
}

.nav-link.active{
  border-color: transparent;
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2));
  color: #04263a;
}

.hero{
  position: relative;
  z-index: 2;
  margin-top: 14px;
  border-radius: 18px;
  border: 1px solid rgba(177, 197, 214, .76);
  background:
    linear-gradient(130deg, rgba(14,165,233,.16), rgba(20,184,166,.12) 45%, rgba(249,115,22,.10)),
    rgba(255,255,255,.80);
  padding: 18px 16px 14px;
}

.hero h1{
  margin: 0;
  font-size: clamp(1.45rem, 3.2vw, 2.18rem);
}

.hero p{
  margin: 9px 0 0;
  max-width: 70ch;
  color: #23495f;
  font-size: 1.02rem;
}

.main-flow{
  margin-top: 18px;
  display: grid;
  gap: 14px;
}

.main-flow > *{
  animation: riseIn .42s ease both;
}

.main-flow > *:nth-child(2){ animation-delay: .05s; }
.main-flow > *:nth-child(3){ animation-delay: .10s; }
.main-flow > *:nth-child(4){ animation-delay: .15s; }
.main-flow > *:nth-child(5){ animation-delay: .20s; }
.main-flow > *:nth-child(6){ animation-delay: .25s; }

.card-panel{
  position: relative;
  overflow: hidden;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(188, 205, 218, .86);
  background:
    linear-gradient(170deg, rgba(255,255,255,.94), rgba(248,252,255,.92));
  box-shadow: var(--shadow-soft);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.card-panel::before{
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2), var(--accent-3));
  opacity: .9;
}

.card-panel:hover{
  transform: translateY(-2px);
  border-color: #9fc0d9;
  box-shadow: 0 22px 42px rgba(16, 45, 66, .14);
}

.card-panel h2{
  margin: 0 0 10px;
  font-size: clamp(1.18rem, 2.4vw, 1.56rem);
}

.card-panel p,
.card-panel li{
  color: #17384d;
}

.card-panel ol,
.card-panel ul{
  margin: 8px 0 0;
  padding-left: 20px;
}

.card-panel li{
  margin: 3px 0;
}

.section-note{
  margin: 0;
  color: var(--muted);
}

.muted{
  color: var(--muted);
}

.meta{
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
}

.stack-list{
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.list-item{
  padding: 13px;
  border-radius: 15px;
  border: 1px solid rgba(193, 210, 222, .9);
  background: linear-gradient(155deg, rgba(245,250,254,.96), rgba(255,255,255,.94));
}

.list-item p{
  margin: 5px 0 0;
}

.text-strong{
  font-weight: 800;
  text-decoration-thickness: 1.5px;
}

.actions{
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.btn{
  text-decoration: none;
  cursor: pointer;
  border-radius: 12px;
  border: 1px solid rgba(165, 188, 205, .95);
  background: linear-gradient(170deg, #ffffff, #f0f7fc);
  color: #12354c;
  min-height: 42px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease, filter .14s ease;
}

.btn:hover{
  transform: translateY(-1px);
  border-color: #8fb6d4;
  box-shadow: 0 10px 22px rgba(21, 49, 69, .16);
}

.btn:disabled{
  opacity: .58;
  filter: grayscale(.16);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn.primary{
  border-color: transparent;
  color: #05263a;
  background: linear-gradient(92deg, var(--accent-1), var(--accent-2));
}

.btn.warm{
  border-color: transparent;
  color: #3a1c00;
  background: linear-gradient(92deg, var(--accent-4), var(--accent-3));
}

.quick-grid{
  margin-top: 10px;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.quick-link{
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 13px;
  border-radius: 13px;
  border: 1px solid rgba(179, 199, 215, .88);
  background: linear-gradient(155deg, rgba(255,255,255,.95), rgba(242,249,255,.93));
  color: #17384d;
  font-weight: 700;
  transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease;
}

.quick-link:hover{
  transform: translateY(-1px);
  border-color: #8eb7d6;
  box-shadow: 0 10px 20px rgba(16, 49, 74, .11);
}

.projects-control{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.chev{
  width: 15px;
  height: 15px;
  transition: transform .16s ease;
}

.btn[aria-expanded="true"] .chev{
  transform: rotate(180deg);
}

.post-card + .post-card{
  margin-top: 10px;
}

.post-content{
  margin-top: 12px;
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4{
  margin: 0 0 12px;
  color: #0c3147;
}

.post-content p{
  margin: 0 0 12px;
}

.post-content ul,
.post-content ol{
  margin: 0 0 12px 22px;
}

.post-content li{
  margin: 3px 0;
}

.post-content blockquote{
  margin: 0 0 12px;
  padding: 10px 12px;
  border-left: 4px solid #7db6d8;
  border-radius: 8px;
  background: #eff8ff;
  color: #224b62;
}

.post-content hr{
  border: none;
  border-top: 1px solid var(--line);
  margin: 16px 0;
}

.post-content pre{
  margin: 0 0 12px;
  border-radius: 12px;
  border: 1px solid #244159;
  background: #0a2232;
  color: #e8f4ff;
  padding: 13px;
  overflow: auto;
}

.post-content code{
  border-radius: 6px;
  background: #e7f3fc;
  padding: 2px 6px;
  font-size: 13px;
  font-family: Consolas, "Courier New", monospace;
}

.post-content pre code{
  background: transparent;
  color: inherit;
  padding: 0;
}

.term-groups{
  margin-top: 16px;
  display: grid;
  gap: 10px;
}

.term-group-title{
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.term-list{
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.term-chip{
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  border: 1px solid #b8d2e5;
  background: #f4faff;
  color: #12405f;
  padding: 5px 10px;
  font-size: 13px;
  font-weight: 700;
}

.term-chip:hover{
  background: #e6f4ff;
  border-color: #88b4d6;
}

.form-grid{
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.field-label{
  display: block;
  margin-bottom: 6px;
  color: #29495d;
  font-size: 14px;
  font-weight: 700;
}

.field-input{
  width: 100%;
  padding: 11px 12px;
  border-radius: 11px;
  border: 1px solid #bfcfdd;
  background: #fff;
  color: var(--ink);
  transition: border-color .16s ease, box-shadow .16s ease;
}

.field-input:hover{
  border-color: #9eb9cd;
}

.field-input.is-invalid{
  border-color: #d85252;
  box-shadow: 0 0 0 3px rgba(216, 82, 82, .18);
}

.field-help{
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.field-error{
  margin: 6px 0 0;
  color: #8f2121;
  font-size: 13px;
  font-weight: 700;
}

.alert{
  border-radius: 13px;
  padding: 11px 12px;
  border: 1px solid transparent;
}

.alert.error{
  color: #8b1f1f;
  border-color: #efc1c1;
  background: #ffeaea;
}

.alert.success{
  color: #135530;
  border-color: #b6eac7;
  background: #e8fff0;
}

.alert.warning{
  color: #7a5112;
  border-color: #f1deb6;
  background: #fff8e8;
}

.key-list{
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.key{
  display: inline-block;
  margin-right: 8px;
  min-width: 98px;
  padding: 2px 8px;
  border-radius: 9px;
  border: 1px solid #c5d8e8;
  background: #f5fbff;
  font-size: 12px;
  font-weight: 800;
  color: #103e5e;
}

.comments-panel h2{
  margin-bottom: 10px;
}

.comment-tree{
  margin-top: 10px;
  display: grid;
  gap: 10px;
}

.comment-node{
  border-radius: 14px;
  border: 1px solid #c7dae8;
  background: #f7fbff;
  padding: 12px;
}

.comment-head{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 10px;
}

.comment-author{
  margin: 0;
  color: #123a53;
  font-weight: 800;
}

.comment-meta{
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.comment-body{
  margin-top: 8px;
  color: #17384d;
  overflow-wrap: anywhere;
}

.comment-body a{
  font-weight: 700;
}

.comment-tools{
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.comment-reply-link{
  text-decoration: none;
  font-weight: 700;
}

.comment-delete{
  padding: 7px 10px;
  font-size: 13px;
}

.comment-children{
  margin-top: 10px;
  margin-left: 18px;
  padding-left: 12px;
  border-left: 3px solid #c5d9e8;
  display: grid;
  gap: 10px;
}

.comment-form{
  margin-top: 14px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid #c4d8e8;
  background: #fff;
}

.comment-form h3{
  margin: 0 0 8px;
}

.hp-field{
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.inline-form{
  display: inline-flex;
  margin: 0;
}

.site-footer{
  margin-top: 16px;
  padding-bottom: 8px;
  text-align: center;
  font-size: 13px;
  color: var(--muted);
}

@keyframes riseIn{
  from{
    opacity: 0;
    transform: translateY(10px);
  }
  to{
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px){
  .brand-row{
    grid-template-columns: 72px 1fr;
  }

  .clock-chip{
    grid-column: 1 / -1;
    justify-self: start;
    width: 100%;
    min-width: 0;
  }

  .brand-logo{
    width: 66px;
    height: 66px;
    border-radius: 15px;
  }

  .hero p{
    max-width: none;
  }
}

@media (max-width: 640px){
  .site-shell{
    padding: 16px 12px 26px;
  }

  .site-header{
    padding: 16px 14px 14px;
  }

  .brand-name{
    font-size: 1.5rem;
  }

  .card-panel{
    padding: 14px;
    border-radius: 18px;
  }
}

@media (prefers-reduced-motion: reduce){
  *{
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
