/* Self-hosted fonts (OFL 1.1: Inter, Noto Sans Thai, JetBrains Mono, Space Grotesk) —
   no font request ever leaves this origin (M3). */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-greek-ext.woff2") format("woff2");
  unicode-range: U+1F00-1FFF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-greek-ext.woff2") format("woff2");
  unicode-range: U+1F00-1FFF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-greek-ext.woff2") format("woff2");
  unicode-range: U+1F00-1FFF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-greek-ext.woff2") format("woff2");
  unicode-range: U+1F00-1FFF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-greek-ext.woff2") format("woff2");
  unicode-range: U+1F00-1FFF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-greek.woff2") format("woff2");
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jetbrainsmono-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-thai.woff2") format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-thai.woff2") format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-thai.woff2") format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-thai.woff2") format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Noto Sans Thai';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/notosansthai-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Space Grotesk variable (300–700) — display face for headings and numerals. */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/assets/fonts/spacegrotesk-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Fraunces variable (300–900 + optical size) — editorial serif display face. */
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url("/assets/fonts/fraunces-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* ============================================================
   ShiftPilot by CHAi — visual system (spec §11)
   v5 "Paper Ops": warm cream editorial, ink rules, hard offset
   shadows, vivid orange signal, serif display (Fraunces),
   mono instrumentation, marquee + playful pointer physics.
   ============================================================ */

:root {
  /* Palette derived from the CHAi logo: deep navy #1A365D + bright azure #2A7FFF. */
  --paper: #f4f7fd;
  --paper-2: #e9eff9;
  --card: #ffffff;
  --ink: #182f52;
  --ink-deep: #122844;
  --logo-navy: #1a365d;
  --ink-soft: #3f5478;
  --muted: #5b6880;   /* 4.61:1 on --paper (was #66738f, 4.43:1) */
  --faint: #5b6880;   /* 4.61:1 on --paper; safe for normal-size supporting text. */
  --line: #d7e0ee;
  --line-soft: #e4ebf5;
  --accent: #2a7fff;
  --accent-strong: #1c5fd6;
  --accent-soft: #e3eeff;
  --accent-ink: #17408c;
  --ok: #157347;
  --ok-soft: #ddf2e5;
  --warn: #9a5b00;
  --warn-soft: #fdeeda;
  --danger: #c81e1e;
  --danger-soft: #fbe3e3;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-sm: 8px;
  --shadow-pop: 4px 4px 0 var(--ink);
  --shadow-pop-lg: 7px 7px 0 var(--ink);
  --shadow-pop-accent: 4px 4px 0 var(--accent);
  --font: "Inter", "Noto Sans Thai", system-ui, -apple-system, sans-serif;
  --font-display: "Fraunces", "Noto Sans Thai", Georgia, serif;
  --mono: "JetBrains Mono", "Noto Sans Thai", ui-monospace, monospace;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.45, 0.5, 1);
}

* { box-sizing: border-box; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html {
  scroll-padding-top: 88px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(900px 480px at 110% -8%, rgba(42, 127, 255, 0.08) 0%, transparent 60%),
    radial-gradient(700px 420px at -12% 22%, rgba(26, 54, 93, 0.05) 0%, transparent 55%),
    var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

::selection { background: var(--accent); color: #fff; }

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

h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

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

/* Reading progress beacon. */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  width: 0;
  background: var(--accent);
  z-index: 60;
  pointer-events: none;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 10px 16px;
  border-radius: 0 0 var(--radius-sm) 0;
  z-index: 100;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none;
}
.skip-link:focus { left: 0; }

/* ---------- Header: masthead rule ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 68px;
  background: rgba(250, 246, 238, 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--ink);
}

.nav-inner {
  height: 68px;
  display: flex;
  align-items: center;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
  flex-shrink: 0;
}

.brand-logo {
  height: 26px;
  width: auto;
  background: #ffffff;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 5px 9px;
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.18rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  box-shadow: 3px 3px 0 var(--ink);
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.nav-toggle:active { transform: translate(2px, 2px); box-shadow: 0 0 0 var(--ink); }

.nav-toggle-bar {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--ink);
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
}

.primary-nav a {
  position: relative;
  color: var(--ink-soft);
  text-decoration: none;
  font-family: var(--mono);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  white-space: nowrap;
  padding: 7px 11px;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  transition: color 0.12s ease, background 0.12s ease, border-color 0.12s ease;
}

.primary-nav a:hover {
  color: var(--ink);
  background: var(--accent-soft);
}

.primary-nav a.active {
  color: var(--accent-ink);
  background: var(--accent-soft);
  border-color: var(--ink);
}

.nav-cta {
  background: var(--logo-navy);
  color: #fff !important;
  font-weight: 700;
  padding: 9px 18px;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  box-shadow: 3px 3px 0 var(--accent);
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

/* Desktop: one header CTA (the language-toggle sibling). The in-nav
   control is the mobile-drawer duplicate and must stay hidden here. */
.primary-nav .nav-cta {
  display: none;
}

.nav-cta:hover {
  background: var(--ink-deep);
  transform: translate(-1px, -1px);
  box-shadow: 5px 5px 0 var(--accent);
}
.nav-cta:active { transform: translate(2px, 2px); box-shadow: 0 0 0 var(--ink); }

.nav-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

.lang-group {
  display: flex;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  background: var(--card);
}

/* `overflow: hidden` here used to clip the focus outline of the buttons inside,
   so keyboard focus on EN/TH was invisible (WCAG 2.4.7). The corners are rounded
   on the children instead. */
.lang-btn:first-child { border-radius: calc(var(--radius-sm) - 2px) 0 0 calc(var(--radius-sm) - 2px); }
.lang-btn:last-child { border-radius: 0 calc(var(--radius-sm) - 2px) calc(var(--radius-sm) - 2px) 0; }

.lang-btn {
  min-width: 42px;
  min-height: 38px;
  border: none;
  background: transparent;
  color: var(--ink-soft);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.78rem;
  cursor: pointer;
  padding: 0 12px;
  transition: color 0.12s ease, background 0.12s ease;
}

.lang-btn + .lang-btn { border-left: 2px solid var(--ink); }

.lang-btn[aria-pressed="true"] {
  background: var(--ink);
  color: var(--paper);
}

.lang-btn:active { background: var(--accent-soft); }

.nav-cta-desktop {
  background: var(--logo-navy);
  color: #fff;
  text-decoration: none;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 11px 20px;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  box-shadow: 3px 3px 0 var(--ink);
  white-space: nowrap;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.nav-cta-desktop { transform: translate(var(--pull-x, 0px), var(--pull-y, 0px)); }
.nav-cta-desktop:hover {
  background: var(--ink);
  transform: translate(var(--pull-x, -1px), var(--pull-y, -1px));
  box-shadow: 4px 4px 0 var(--accent);
}
.nav-cta-desktop:active { transform: translate(var(--pull-x, 2px), var(--pull-y, 2px)); box-shadow: 0 0 0 var(--ink); }

/* ---------- Hero: big serif statement + sticky-note collage ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 92px 0 96px;
  background: var(--paper);
  border-bottom: 2px solid var(--ink);
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* Cursor spotlight (JS-positioned). */
.hero-spot {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(42, 127, 255, 0.16) 0%, transparent 62%);
  transform: translate(-50%, -50%);
  left: 70%;
  top: 40%;
  transition: opacity 0.3s ease;
}

/* Flat editorial shapes. */
.hero-shape-ring {
  position: absolute;
  width: 190px;
  height: 190px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  right: -46px;
  top: 54px;
  opacity: 0.14;
}

.hero-shape-grid {
  position: absolute;
  left: -30px;
  bottom: -34px;
  width: 210px;
  height: 150px;
  background-image:
    linear-gradient(to right, rgba(23, 47, 82, 0.15) 1.5px, transparent 1.5px),
    linear-gradient(to bottom, rgba(23, 47, 82, 0.15) 1.5px, transparent 1.5px);
  background-size: 26px 26px;
  -webkit-mask-image: linear-gradient(45deg, #000 30%, transparent 75%);
  mask-image: linear-gradient(45deg, #000 30%, transparent 75%);
}

.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.06fr 0.94fr;
  gap: 56px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--card);
  color: var(--ink);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  padding: 8px 14px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink);
  margin: 0 0 24px;
  transform: rotate(-1.2deg);
}

.hero-badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--ink);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.015em;
  margin: 0 0 22px;
  font-weight: 640;
  font-variation-settings: "opsz" 96;
}

:lang(th) .hero-title,
:lang(th) .section-title,
:lang(th) .principle-quote,
:lang(th) .cta-title { line-height: 1.34; }

.hero-title .accent {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 6px;
  text-underline-offset: 8px;
}

.hero-sub {
  color: var(--ink-soft);
  font-size: 1.12rem;
  line-height: 1.65;
  max-width: 52ch;
  margin: 0 0 34px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* --- Sticky-note collage --- */

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  padding: 26px 0 34px;
}

.hero-note-wrap {
  position: relative;
  width: 100%;
  max-width: 440px;
  animation: note-bob 6s ease-in-out infinite;
}

@keyframes note-bob {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-9px) rotate(-1.2deg); }
}

/* Small sticky note tucked behind. */
.hero-note-behind {
  position: absolute;
  top: -26px;
  right: -20px;
  width: 132px;
  height: 112px;
  background: var(--accent);
  border: 2px solid var(--ink);
  border-radius: 6px;
  box-shadow: 4px 4px 0 var(--ink);
  transform: rotate(6deg);
  z-index: 1;
}

.hero-note-behind::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -11px;
  transform: translateX(-50%) rotate(-3deg);
  width: 64px;
  height: 18px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(23, 47, 82, 0.25);
}

/* The condition card itself, styled as a pinned paper card. */
.hero-note {
  position: relative;
  z-index: 2;
  width: 100%;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow-pop-lg);
  padding: 30px 30px 28px;
  transition: transform 0.25s var(--ease-spring), box-shadow 0.25s ease;
}

.hero-note:hover {
  transform: rotate(0deg) translateY(-4px);
  box-shadow: 10px 12px 0 var(--ink);
}

/* Tape strips holding the note down. */
.hero-note-tape {
  position: absolute;
  top: -13px;
  width: 96px;
  height: 26px;
  background: rgba(42, 127, 255, 0.28);
  border: 1.5px solid rgba(23, 47, 82, 0.4);
}

.hero-note-tape-l { left: 34px; transform: rotate(-5deg); }
.hero-note-tape-r { right: 34px; transform: rotate(4deg); background: rgba(26, 54, 93, 0.18); }

.hero-card-title {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--paper);
  background: var(--ink);
  display: inline-block;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  margin: 0 0 16px;
}

.hero-card-rule {
  font-family: var(--font-display);
  font-size: 1.42rem;
  font-weight: 640;
  letter-spacing: -0.01em;
  line-height: 1.25;
  color: var(--ink);
  margin: 0 0 16px;
}

.hero-card-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-soft);
  color: var(--accent-ink);
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 6px 12px;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  margin: 0 0 18px;
}

.hero-card-chip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--accent);
  border: 1.5px solid var(--ink);
}

.hero-card-status {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink-soft);
  font-size: 0.92rem;
  margin: 0;
  padding-top: 14px;
  border-top: 2px dashed var(--line);
}

.hero-card-status::before {
  content: "";
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 3px solid var(--accent);
  flex-shrink: 0;
  animation: status-breathe 2.4s ease-in-out infinite;
}

@keyframes status-breathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.25); }
}

/* Rubber-stamp flourish. */
.hero-note-stamp {
  position: absolute;
  right: 18px;
  bottom: 60px;
  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  border: 2px solid var(--accent);
  border-radius: 4px;
  padding: 3px 7px;
  transform: rotate(-10deg);
  opacity: 0.85;
}

/* Hero entrance. */
@keyframes hero-rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-badge,
.hero-title,
.hero-sub,
.hero-actions,
.hero-visual {
  animation: hero-rise 0.55s var(--ease-out) both;
}

.hero-title { animation-delay: 0.06s; }
.hero-sub { animation-delay: 0.12s; }
.hero-actions { animation-delay: 0.18s; }
.hero-visual { animation-delay: 0.1s; }

/* ---------- Ticker: scrolling paper band ---------- */

.ticker {
  overflow: hidden;
  background: var(--ink);
  color: var(--paper);
  border-bottom: 2px solid var(--ink);
  padding: 12px 0;
  position: relative;
}

.ticker:hover .ticker-track { animation-play-state: paused; }

.ticker-track {
  display: flex;
  width: max-content;
  animation: ticker-scroll 36s linear infinite;
}

@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.ticker-group {
  display: flex;
  align-items: center;
  gap: 34px;
  padding-right: 34px;
  white-space: nowrap;
}

.ticker-group span {
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--paper);
}

.ticker-group span.hot { color: #a8ccff; }

.ticker-group i {
  font-style: normal;
  color: var(--accent);
  font-size: 0.85rem;
}

/* ---------- Buttons: press blocks ---------- */

/* The [hidden] attribute must win over display utilities below (UA rule is
   weaker than .btn/.engine-badge); without this, fallback-mode buttons stay
   visible. */
[hidden] {
  display: none !important;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 12px 26px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--ink);
  font-family: var(--mono);
  font-size: 0.86rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-pop);
  transition: transform 0.13s ease, box-shadow 0.13s ease, background 0.13s ease,
    color 0.13s ease;
}

.btn {
  transform: translate(var(--pull-x, 0px), var(--pull-y, 0px));
}
.btn:hover { transform: translate(var(--pull-x, -2px), var(--pull-y, -2px)); box-shadow: 6px 6px 0 var(--ink); }
.btn:active { transform: translate(var(--pull-x, 3px), var(--pull-y, 3px)); box-shadow: 0 0 0 var(--ink); }

.btn-primary {
  background: var(--logo-navy);
  color: #fff;
  box-shadow: 4px 4px 0 var(--accent);
}

.btn-primary:hover { background: var(--ink-deep); }

.btn-primary:hover { box-shadow: 6px 6px 0 var(--accent); }

.btn-primary:disabled {
  background: var(--line);
  color: var(--faint);
  box-shadow: 2px 2px 0 var(--ink);
  cursor: not-allowed;
  transform: none;
}

.btn-ghost {
  background: var(--card);
  color: var(--ink);
}

.btn-ghost:hover { background: var(--paper-2); }

/* ---------- Sections ---------- */

.section {
  padding: 92px 0;
  scroll-margin-top: 88px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.4vw, 2.6rem);
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin: 0 0 14px;
  font-weight: 640;
  font-variation-settings: "opsz" 80;
}

.section-sub {
  color: var(--ink-soft);
  font-size: 1.06rem;
  max-width: 62ch;
  margin: 0 0 44px;
}

.section-kicker {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 700;
  font-size: 0.72rem;
  color: var(--accent);
  margin: 0 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.section-kicker::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--accent);
}

/* ---------- Principle: orange broadside ---------- */

.principle {
  background: var(--logo-navy);
  color: #fff;
  padding: 96px 0;
  border-bottom: 2px solid var(--ink);
  position: relative;
  overflow: hidden;
}

/* Halftone dot texture. */
.principle::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1.2px, transparent 1.6px);
  background-size: 17px 17px;
  pointer-events: none;
}

.principle .container { position: relative; z-index: 1; }

.principle .section-kicker { color: #a8ccff; }
.principle .section-kicker::before { background: #a8ccff; }

.principle-quote {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3.6vw, 2.6rem);
  font-weight: 640;
  letter-spacing: -0.015em;
  line-height: 1.16;
  max-width: 26ch;
  margin: 0 0 54px;
  text-wrap: balance;
  color: #fff;
}

.principle-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  counter-reset: principle-step;
}

.principle-card {
  counter-increment: principle-step;
  background: #e9f1ff;
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 26px 26px 24px;
  box-shadow: var(--shadow-pop);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.principle-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--ink);
}

.principle-card::before {
  content: "0" counter(principle-step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
  background: var(--ink);
  border-radius: 50%;
  margin-bottom: 16px;
}

.principle-card h3 {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 1.16rem;
  font-weight: 640;
  color: var(--ink);
}

.principle-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.94rem;
  line-height: 1.7;
}

.principle-note {
  margin: 34px 0 0;
  color: #c9dbf7;
  font-size: 0.9rem;
  font-family: var(--mono);
}

/* ---------- How: numbered ledger ---------- */

.how { background: var(--paper-2); }

.how-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.how-card {
  position: relative;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 24px 22px 22px;
  box-shadow: var(--shadow-pop);
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.how-card:nth-child(1) { transform: rotate(-0.6deg); }
.how-card:nth-child(2) { transform: rotate(0.5deg); }
.how-card:nth-child(3) { transform: rotate(-0.4deg); }
.how-card:nth-child(4) { transform: rotate(0.6deg); }

.how-card:nth-child(1):hover,
.how-card:nth-child(2):hover,
.how-card:nth-child(3):hover,
.how-card:nth-child(4):hover {
  transform: rotate(0deg) translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--ink);
}

.how-card h3 {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 1.06rem;
  font-weight: 640;
  color: var(--ink);
}

.how-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
  line-height: 1.65;
}

/* ---------- Demo: the worksheet ---------- */

.demo { scroll-margin-top: 88px; background: var(--paper); }

.demo-panel {
  position: relative;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop-lg);
  padding: 36px;
}

/* Corner "screws". */
.demo-panel::before,
.sched-panel::before {
  content: "";
  position: absolute;
  inset: 12px;
  pointer-events: none;
  background:
    radial-gradient(circle 3px at 4px 4px, var(--ink) 2.2px, transparent 2.6px),
    radial-gradient(circle 3px at calc(100% - 4px) 4px, var(--ink) 2.2px, transparent 2.6px),
    radial-gradient(circle 3px at 4px calc(100% - 4px), var(--ink) 2.2px, transparent 2.6px),
    radial-gradient(circle 3px at calc(100% - 4px) calc(100% - 4px), var(--ink) 2.2px, transparent 2.6px);
}

.demo-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-ink);
  background: var(--accent-soft);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 4px 10px;
  margin: 0 0 10px;
}

.demo-label::before { content: "№"; color: var(--accent); }

.demo-input {
  width: 100%;
  font-family: var(--font);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 13px 15px;
  resize: vertical;
  min-height: 88px;
  box-shadow: inset 3px 3px 0 rgba(23, 47, 82, 0.07);
  transition: box-shadow 0.15s ease, background 0.15s ease;
}

.demo-input:focus {
  outline: none;
  background: #fff;
  box-shadow: inset 3px 3px 0 rgba(23, 47, 82, 0.07), 0 0 0 3px var(--accent);
}

.demo-examples-label {
  margin: 20px 0 10px;
  font-family: var(--mono);
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.demo-chips {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.chip-btn {
  min-height: 42px;
  padding: 8px 18px;
  border-radius: 999px;
  border: 2px solid var(--ink);
  background: var(--card);
  color: var(--ink);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  box-shadow: 3px 3px 0 var(--ink);
  transition: transform 0.13s ease, box-shadow 0.13s ease, background 0.13s ease;
}

.chip-btn { transform: translate(var(--pull-x, 0px), var(--pull-y, 0px)); }
.chip-btn:hover { transform: translate(var(--pull-x, -2px), var(--pull-y, -2px)); box-shadow: 5px 5px 0 var(--ink); background: var(--accent-soft); }
.chip-btn:active { transform: translate(var(--pull-x, 2px), var(--pull-y, 2px)); box-shadow: 0 0 0 var(--ink); }

.demo-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.demo-progress {
  height: 8px;
  background: var(--paper-2);
  border: 2px solid var(--ink);
  border-radius: 999px;
  overflow: hidden;
  margin: 8px 0 12px;
}

.demo-progress-bar {
  height: 100%;
  width: 40%;
  background: repeating-linear-gradient(-55deg, var(--accent) 0 10px, var(--ink) 10px 20px);
  animation: progress-slide 1.1s infinite linear;
}

@keyframes progress-slide {
  from { transform: translateX(-120%); }
  to { transform: translateX(280%); }
}

@media (prefers-reduced-motion: reduce) {
  .demo-progress-bar {
    animation: none;
    transform: translateX(0);
    width: 100%;
  }
  html {
    scroll-behavior: auto;
  }
}

.demo-status {
  min-height: 1.4em;
  color: var(--ink-soft);
  font-family: var(--mono);
  font-size: 0.85rem;
  margin: 0 0 8px;
}

.demo-results { margin-top: 26px; }

.demo-results-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 2px dashed var(--line);
}

.demo-results-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 640;
}

.engine-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 999px;
  border: 2px solid var(--ink);
}

.engine-badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}

.engine-badge.ai { background: var(--ok-soft); color: var(--ok); }
.engine-badge.mock { background: var(--warn-soft); color: var(--warn); }
.engine-badge.failed { background: var(--danger-soft); color: var(--danger); }

.demo-cards {
  display: grid;
  gap: 16px;
}

/* ---------- Condition cards: index slips ---------- */

.condition-card {
  position: relative;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 22px 24px;
  scroll-margin-top: 88px;
  box-shadow: var(--shadow-pop);
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.2s ease;
}

.condition-card:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }

.condition-card.confirmed {
  background: linear-gradient(120deg, var(--ok-soft), var(--card) 46%);
}

.condition-card.rejected {
  background: linear-gradient(120deg, var(--danger-soft), var(--card) 46%);
  border-color: var(--danger);
  box-shadow: 4px 4px 0 var(--danger);
}

.condition-card.rejected:hover { box-shadow: 6px 6px 0 var(--danger); }

.card-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.card-type {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--paper);
  background: var(--ink);
  padding: 3px 9px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.card-paraphrase {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.16rem;
  font-weight: 640;
  line-height: 1.35;
}

.card-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0 16px;
}

.chip {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--ink);
  background: var(--paper);
  color: var(--ink-soft);
}

.chip.enf-hard-pending { background: var(--accent-soft); color: var(--accent-ink); }
.chip.enf-soft-high { background: var(--ok-soft); color: var(--ok); }
.chip.enf-soft-normal { background: var(--paper); color: var(--ink); }
.chip.enf-unresolved { background: var(--warn-soft); color: var(--warn); }

.chip.approval-yes { background: var(--warn-soft); color: var(--warn); }
.chip.approval-no { background: var(--paper); color: var(--muted); }

.card-block { margin: 12px 0; }

.card-block h4 {
  margin: 0 0 6px;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.card-block h4::before { content: "» "; color: var(--accent); }

.card-block ul {
  margin: 0;
  padding-left: 18px;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

/* Structured block: receipt well. Noto Sans Thai is in --mono so Thai
   glyphs in SCIR/code do not tofu (JetBrains Mono is Latin-only). */
.card-structured pre {
  margin: 0;
  font-family: var(--mono), "Noto Sans Thai", sans-serif;
  font-size: 0.79rem;
  line-height: 1.6;
  background: #f2f7ff;
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  overflow-x: auto;
  white-space: pre;
  tab-size: 2;
  box-shadow: inset 3px 3px 0 rgba(23, 47, 82, 0.06);
}

.card-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.card-btn {
  min-height: 42px;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--ink);
  background: var(--card);
  color: var(--ink);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  box-shadow: 3px 3px 0 var(--ink);
  transition: transform 0.13s ease, box-shadow 0.13s ease, background 0.13s ease;
}

.card-btn { transform: translate(var(--pull-x, 0px), var(--pull-y, 0px)); }
.card-btn:hover { transform: translate(var(--pull-x, -2px), var(--pull-y, -2px)); box-shadow: 5px 5px 0 var(--ink); }
.card-btn:active { transform: translate(var(--pull-x, 2px), var(--pull-y, 2px)); box-shadow: 0 0 0 var(--ink); }

.card-btn.confirm[aria-pressed="true"] {
  background: var(--ok);
  color: #fff;
}

.card-btn.reject[aria-pressed="true"] {
  background: var(--danger);
  color: #fff;
}

.card-btn.strength {
  margin-left: auto;
  border-style: dashed;
  box-shadow: none;
}

/* ---------- Features: sticker board ---------- */

.features { background: var(--paper-2); }

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.feature-tile {
  position: relative;
  display: flex;
  gap: 18px;
  align-items: flex-start;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-pop);
  counter-increment: feature-index;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.features-grid { counter-reset: feature-index; }

.feature-tile:nth-child(odd) { transform: rotate(-0.5deg); }
.feature-tile:nth-child(even) { transform: rotate(0.5deg); }

.feature-tile:hover {
  transform: rotate(0deg) translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--ink);
  background: #fff;
}

/* Pop-out index number. */
.feature-tile::before {
  content: counter(feature-index, decimal-leading-zero);
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 2px;
  min-width: 44px;
}

.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--accent-soft);
  margin-left: auto;
  flex-shrink: 0;
  order: 3;
  transition: background 0.15s ease, color 0.15s ease, transform 0.2s var(--ease-spring);
}

.feature-tile:hover .feature-icon {
  background: var(--accent);
  color: #fff;
  transform: rotate(-8deg) scale(1.08);
}

.feature-icon svg {
  width: 21px;
  height: 21px;
}

.feature-tile h3 {
  margin: 0 0 4px;
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 640;
  color: var(--ink);
}

.feature-tile p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* The wide strip tile spans both columns. */
.feature-tile.span-1,
.feature-tile.span-2,
.feature-tile.span-3,
.feature-tile.span-4,
.feature-tile.span-5,
.feature-tile.span-6,
.feature-tile.span-7,
.feature-tile.span-8,
.feature-tile.span-9 {
  grid-column: auto;
  display: flex;
  align-items: flex-start;
}

.feature-tile.span-9 { grid-column: 1 / -1; background: var(--accent-soft); }

/* ---------- Verticals: tag wall ---------- */

.verticals-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.verticals-grid { border: none; background: none; }

.vertical-tile {
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 14px 18px 12px;
  background: var(--card);
  box-shadow: 3px 3px 0 var(--ink);
  position: relative;
  transition: transform 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
}

.vertical-tile:nth-child(3n) { transform: rotate(0.8deg); }
.vertical-tile:nth-child(3n + 1) { transform: rotate(-0.7deg); }

.vertical-tile:hover {
  transform: rotate(0deg) translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--ink);
  background: var(--accent-soft);
  z-index: 1;
}

.vertical-tile h3 {
  margin: 0 0 3px;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 640;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 8px;
}

.vertical-tile h3::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--ink);
  flex-shrink: 0;
}

.vertical-tile p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.85rem;
  line-height: 1.5;
}

/* ---------- Deployment: staircase ---------- */

.deployment { background: var(--paper-2); }

.deployment-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  align-items: start;
}

.deployment-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--card);
  box-shadow: var(--shadow-pop);
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

/* Descending staircase. */
.deployment-tile:nth-child(1) { margin-top: 0; }
.deployment-tile:nth-child(2) { margin-top: 26px; }
.deployment-tile:nth-child(3) { margin-top: 52px; }
.deployment-tile:nth-child(4) { margin-top: 78px; background: var(--ink); color: var(--paper); }

.deployment-tile:nth-child(4) h3 { color: var(--paper); }
.deployment-tile:nth-child(4) p { color: #cfc4b4; }

.deployment-tile:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--accent);
}

.deployment-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  border: 2px solid var(--ink);
  color: var(--accent-ink);
  margin: 0;
}

.deployment-tile:nth-child(4) .deployment-icon {
  background: var(--accent);
  color: #fff;
}

.deployment-icon svg {
  width: 20px;
  height: 20px;
}

.deployment-meter {
  display: flex;
  gap: 5px;
  margin: 0;
}

.deployment-meter i {
  width: 20px;
  height: 7px;
  border-radius: 2px;
  border: 2px solid var(--ink);
  background: var(--card);
}

.deployment-meter i.on { background: var(--accent); }

.deployment-tile:nth-child(4) .deployment-meter i { background: var(--ink); border-color: var(--paper); }
.deployment-tile:nth-child(4) .deployment-meter i.on { background: var(--accent); }

.deployment-tile h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.06rem;
  font-weight: 640;
  color: var(--ink);
}

.deployment-tile p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ---------- CTA: poster block ---------- */

.cta-inner {
  position: relative;
  overflow: hidden;
  text-align: center;
  background: var(--accent-strong);
  border: 2px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop-lg);
  padding: 88px 32px;
  color: #fff;
}

/* Halftone corner texture. */
.cta-inner::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.14) 1.2px, transparent 1.6px);
  background-size: 17px 17px;
  pointer-events: none;
}

.cta-inner > * { position: relative; z-index: 1; }

.cta-inner .section-title { color: #fff; }

.cta-inner .section-sub {
  color: #e4f0ff;
  margin-left: auto;
  margin-right: auto;
}

.cta-inner .btn-primary {
  background: #fff;
  color: var(--logo-navy);
  box-shadow: 5px 5px 0 var(--ink);
}

.cta-inner .btn-primary:hover { background: var(--accent-soft); }

.cta-note {
  color: #dce9ff;
  font-family: var(--mono);
  font-size: 0.8rem;
  margin-top: 20px;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 2px solid var(--ink);
  padding: 52px 0 44px;
  background: var(--paper-2);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}

.footer-logo {
  height: 26px;
  width: auto;
  background: #ffffff;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 5px 9px;
  margin-bottom: 14px;
}

.footer-product {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.02rem;
  margin: 0 0 6px;
}

.footer-tagline {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
  max-width: 40ch;
}

.footer-legal p {
  margin: 0 0 6px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
}

/* ---------- 404 page ---------- */

.notfound {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(700px 380px at 50% -10%, rgba(42, 127, 255, 0.10) 0%, transparent 65%),
    var(--paper);
}

.notfound-card {
  position: relative;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop-lg);
  max-width: 560px;
  width: 100%;
  padding: 56px 42px 52px;
  text-align: center;
  transform: rotate(-0.8deg);
}

.notfound-lang {
  position: absolute;
  top: 16px;
  right: 16px;
}

.notfound-logo {
  height: 30px;
  width: auto;
  margin: 0 auto 22px;
  background: #ffffff;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 5px 9px;
}

.notfound-code {
  font-family: var(--font-display);
  font-size: clamp(4.2rem, 11vw, 6.6rem);
  font-weight: 800;
  line-height: 1;
  margin: 0 0 14px;
  color: var(--accent);
  text-shadow: 5px 5px 0 var(--ink);
  letter-spacing: -0.02em;
}

.notfound-card h1 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin: 0 0 12px;
}

.notfound-lead {
  color: var(--ink-soft);
  margin: 0 0 8px;
}

.notfound-sub {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0 0 30px;
}

.notfound-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------- Synthetic examples gallery ---------- */

.demo-more {
  margin: -8px 0 20px;
  font-size: 0.88rem;
}

.demo-more a {
  /* The only route from the demo to the gallery; inline it was a 20px-tall target. */
  display: inline-block;
  padding: 4px 0 5px;
  color: var(--accent-strong);
  font-family: var(--mono);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid var(--accent);
  transition: color 0.12s ease;
}

.demo-more a:hover { color: var(--ink); }

.examples-page { scroll-margin-top: 88px; background: var(--paper); }

.example-how {
  position: relative;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 26px 30px;
  margin-bottom: 42px;
  box-shadow: var(--shadow-pop);
}

.example-steps {
  margin: 0;
  padding-left: 20px;
  color: var(--ink);
}

.example-steps li {
  margin-bottom: 8px;
}

.example-steps li::marker {
  color: var(--accent);
  font-family: var(--mono);
  font-weight: 700;
}

.example-steps li:last-child {
  margin-bottom: 0;
}

.example-note {
  margin: 16px 0 0;
  padding-top: 14px;
  border-top: 2px dashed var(--line);
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.examples-list {
  display: grid;
  gap: 20px;
}

.example-item {
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius-lg);
  padding: 28px 30px;
  box-shadow: var(--shadow-pop);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.example-item:hover { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 var(--ink); }

.example-title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 640;
  color: var(--ink);
}

.example-desc {
  margin: 0 0 20px;
  color: var(--ink-soft);
  font-size: 0.93rem;
}

.example-io {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 26px;
  align-items: start;
}

.example-io h4 {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.example-io h4::before { content: "» "; color: var(--accent); }

.example-input pre {
  margin: 0 0 14px;
  font-family: var(--mono), "Noto Sans Thai", sans-serif;
  font-size: 0.83rem;
  line-height: 1.65;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-left: 6px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--ink);
}

.example-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.example-actions .try-btn { text-decoration: none; }

.example-readonly {
  margin: 10px 0 0;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.76rem;
}

@media (max-width: 960px) {
  .example-io {
    grid-template-columns: 1fr;
  }
}

/* ---------- Team schedule ---------- */

.demo-person {
  width: 100%;
  font-family: var(--font);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-bottom: 20px;
  box-shadow: inset 3px 3px 0 rgba(23, 47, 82, 0.06);
  transition: box-shadow 0.15s ease, background 0.15s ease;
}

.demo-person:focus,
.sched-shift-start:focus,
#sched-days:focus {
  outline: none;
  background: #fff;
  box-shadow: inset 3px 3px 0 rgba(23, 47, 82, 0.05), 0 0 0 3px var(--accent);
}

.schedule { scroll-margin-top: 88px; }

.sched-panel {
  position: relative;
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop-lg);
  padding: 36px;
}

.sched-block { margin-bottom: 26px; }

.sched-block-title {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-size: 1.14rem;
  font-weight: 640;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sched-block-title::before {
  content: "";
  width: 12px;
  height: 12px;
  background: var(--accent);
  border: 2px solid var(--ink);
  border-radius: 3px;
  flex-shrink: 0;
}

.sched-empty {
  color: var(--ink-soft);
  font-size: 0.9rem;
  margin: 0;
  padding: 14px 18px;
  border: 2px dashed var(--ink);
  border-radius: var(--radius-sm);
  background: var(--paper);
}

.sched-team {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.team-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--accent-soft);
  border: 2px solid var(--ink);
  color: var(--ink);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 3px 3px 0 var(--ink);
  transition: transform 0.13s ease, box-shadow 0.13s ease;
}

.team-chip:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--ink); }

.team-chip .team-chip-count {
  color: var(--accent-ink);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.team-chip .team-chip-remove {
  border: none;
  background: none;
  color: var(--ink-soft);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.8rem;
  padding: 2px 4px;
  min-height: 28px;
  border-radius: 6px;
  transition: color 0.12s ease;
}

.team-chip .team-chip-remove:hover { color: var(--danger); }

.sched-shifts { display: grid; gap: 10px; max-width: 480px; }

.sched-shift-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.sched-shift-name {
  min-width: 80px;
  font-family: var(--font-display);
  font-weight: 640;
  font-size: 0.98rem;
  color: var(--ink);
}

.sched-shift-start-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
}

.sched-shift-start {
  font-family: var(--mono);
  font-size: 0.9rem;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
}

.sched-shift-hours {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

.sched-days-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

#sched-days {
  width: 78px;
  font-family: var(--mono);
  font-size: 0.9rem;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
  font-variant-numeric: tabular-nums;
}

.sched-period { font-family: var(--mono); font-size: 0.76rem; }

.sched-grid-wrap {
  overflow-x: auto;
  margin: 16px 0 8px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--card);
}

.sched-grid {
  border-collapse: collapse;
  width: 100%;
  min-width: 520px;
  font-size: 0.88rem;
  font-variant-numeric: tabular-nums;
}

.sched-grid th,
.sched-grid td {
  border: 1.5px solid var(--line);
  padding: 10px 14px;
  text-align: left;
  vertical-align: top;
}

.sched-grid thead th {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.sched-grid .sched-day-cell {
  white-space: nowrap;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 0.76rem;
  font-weight: 700;
}

.sched-grid td.sched-cell-night { background: #eef4fd; }

.sched-person {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent-ink);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-sm);
  padding: 2px 9px;
  margin: 2px 4px 2px 0;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.78rem;
}

.sched-verify { margin: 14px 0 6px; }

.sched-verify-note {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ok);
  font-family: var(--mono);
  font-size: 0.84rem;
  font-weight: 700;
  margin: 0 0 6px;
}

.sched-verify-note.partial { color: var(--warn); }

.sched-verify-label {
  margin: 12px 0 6px;
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink-soft);
}

.sched-verify-hint {
  margin: 12px 0 0;
  font-size: 0.86rem;
  color: var(--ink-soft);
}

.sched-verify ul {
  margin: 0;
  padding-left: 18px;
  font-family: var(--mono);
  font-size: 0.8rem;
}

.sched-verify .v-hard { color: var(--danger); }
.sched-verify .v-gap { color: var(--warn); }
.sched-verify .v-soft { color: var(--ink-soft); }
.sched-verify .v-na { color: var(--muted); opacity: 0.85; }

.sched-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}

@media (max-width: 560px) {
  .sched-panel { padding: 22px 16px; }
  .sched-panel::before, .demo-panel::before { inset: 7px; }
  .demo-panel { padding: 22px 16px; }
}

/* ---------- Scroll reveal (progressive: hidden only when JS is present) ---------- */

html.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s var(--ease-out);
  transition-delay: var(--reveal-delay, 0s);
}

html.js .reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html.js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hero-badge,
  .hero-title,
  .hero-sub,
  .hero-actions,
  .hero-visual,
  .hero-note-wrap,
  .hero-card-status::before,
  .ticker-track {
    animation: none;
  }
  .ticker-track { transform: none; }
  .how-card,
  .vertical-tile,
  .example-item,
  .team-chip,
  .btn,
  .chip-btn,
  .card-btn,
  .feature-tile,
  .deployment-tile,
  .condition-card,
  .principle-card,
  .hero-note {
    transition: none;
  }
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }

  .nav-cta-desktop { display: none; }

  .primary-nav {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    background: var(--paper);
    border-bottom: 2px solid var(--ink);
    box-shadow: 0 18px 30px -14px rgba(23, 47, 82, 0.30);
    padding: 14px 24px 20px;
  }

  .primary-nav.open { display: flex; }

  .primary-nav a {
    padding: 13px 12px;
    font-size: 0.85rem;
  }

  .primary-nav .nav-cta {
    display: block;
    margin-top: 10px;
    text-align: center;
  }

  .hero { padding: 64px 0 72px; }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .hero-note-behind { right: -8px; top: -20px; width: 108px; height: 96px; }
  .hero-shape-ring { display: none; }

  .principle-grid { grid-template-columns: 1fr; }

  .how-grid { grid-template-columns: repeat(2, 1fr); }

  .deployment-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }

  .deployment-tile:nth-child(1),
  .deployment-tile:nth-child(2) { margin-top: 0; }
  .deployment-tile:nth-child(3) { margin-top: 26px; }
  .deployment-tile:nth-child(4) { margin-top: 26px; }

  .features-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .section { padding: 64px 0; }
  .principle { padding: 64px 0; }
  .demo { padding-top: 64px; }

  .how-grid,
  .deployment-grid {
    grid-template-columns: 1fr;
  }

  .deployment-tile:nth-child(n) { margin-top: 0; }

  .feature-tile { flex-wrap: wrap; }
  .feature-icon { order: 0; margin-left: 0; }

  .cta-inner { padding: 60px 20px; }
  .example-item { padding: 22px 18px; }
  .hero-note-tape-r { display: none; }
}

@media (max-width: 400px) {
  .container { padding: 0 16px; }

  .nav-inner { gap: 10px; }

  .wordmark { font-size: 1rem; }
}
