@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./assets/fonts/inter-regular.ttf") format("truetype");
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url("./assets/fonts/inter-semibold.ttf") format("truetype");
}

@font-face {
  font-family: "Noto Sans Thai";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./assets/fonts/noto-sans-thai-regular.ttf") format("truetype");
}

@font-face {
  font-family: "Noto Sans Thai";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url("./assets/fonts/noto-sans-thai-medium.ttf") format("truetype");
}

:root {
  color-scheme: light;
  --forest: #214d40;
  --ink: #2d4038;
  --muted: #68735f;
  --page: #f6f8f3;
  --border: #e3e8df;
  --font: Inter, "Noto Sans Thai", sans-serif;
  font-family: var(--font);
  color: var(--ink);
  background: var(--page);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}

* { box-sizing: border-box; }

body {
  display: flex;
  flex-direction: column;
  min-width: 320px;
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
}

button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }
button, a, input { touch-action: manipulation; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: 3px solid #8eaa6f;
  outline-offset: 5px;
}
p, h1, h2, h3 { margin: 0; }
[hidden] { display: none !important; }

.container { width: min(1048px, calc(100% - 64px)); margin-inline: auto; }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 24px; height: 24px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 20px; top: 12px; z-index: 10; padding: 12px 18px; border-radius: 8px; color: var(--forest); background: white; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }

.hero { position: relative; height: 295px; flex: 0 0 auto; overflow: hidden; background: var(--forest); color: #f7f8f1; }
.hero-content { position: relative; z-index: 1; }
.masthead { display: flex; align-items: center; justify-content: space-between; padding-top: 28px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-mark { position: relative; display: block; width: 42px; height: 47px; border: 1px solid #78968a; border-radius: 14px; }
.brand-mark span { position: absolute; top: 4px; left: 7px; font-size: 32px; line-height: 38px; font-weight: 600; letter-spacing: -3px; }
.brand-mark span + span { top: 11px; left: 17px; color: #b3ce94; }
.brand-mark span:first-child { z-index: 1; }
.brand-wordmark { display: flex; flex-direction: column; gap: 4px; }
.brand-name { font-size: 19px; line-height: 24px; font-weight: 600; letter-spacing: 1px; }
.brand-subtitle { color: #b0c0af; font-size: 8px; line-height: 12px; letter-spacing: 2px; }
.workspace-label { display: inline-flex; align-items: center; gap: 10px; color: #b0c0af; font-size: 8px; line-height: 14px; letter-spacing: 2.2px; }
.status-dot { width: 4px; height: 4px; border-radius: 50%; background: #a7c38c; box-shadow: 0 0 8px #a7c38c20; }
.welcome { margin-top: 46px; }
.eyebrow { color: #bdcdb6; font-size: 9px; line-height: 16px; letter-spacing: 2px; }
.welcome h1 { margin-top: 12px; font-size: 34px; font-weight: 500; line-height: 1.55; letter-spacing: -1.1px; }
.company-name { margin-top: 4px; color: #b4c5b5; font-size: 13px; line-height: 22px; }
.hero-orbit { position: absolute; top: -9px; left: calc(50% + 112px); width: 538px; height: 538px; border: 44px solid #c7d7b508; border-radius: 50%; }
.hero-orbit::before { position: absolute; inset: 0; border: 45px solid #c7d7b510; border-radius: 50%; content: ""; }
.hero-orbit span { position: absolute; top: 95px; left: 95px; width: 7px; height: 7px; border-radius: 50%; background: #abc78c; box-shadow: 0 0 10px #abc78c15; }

.main-content { position: relative; flex: 1 0 auto; padding-bottom: 56px; }
.search-box { position: relative; z-index: 2; display: flex; align-items: center; gap: 14px; height: 56px; margin-top: -25px; padding: 0 19px; border: 1px solid #e1e6df; border-radius: 11px; background: #fff; box-shadow: 0 5px 20px #243e3004; transition: border-color .2s, box-shadow .2s; }
.search-box:focus-within { border-color: #91a68b; box-shadow: 0 0 0 3px #91a68b18; }
.search-icon { width: 19px; height: 19px; color: #929b87; }
.search-box input { width: 100%; min-width: 0; height: 100%; padding: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 12px; line-height: 20px; }
.search-box input:focus-visible { outline: 0; }
.search-box input::placeholder { color: #6e7965; opacity: 1; }
.search-box input::-webkit-search-cancel-button, .search-box input::-webkit-search-decoration { -webkit-appearance: none; }
.search-shortcut { display: grid; place-items: center; width: 22px; height: 19px; flex: 0 0 auto; border: 1px solid #eceee8; border-radius: 4px; color: #6e7965; font-family: var(--font); font-size: 10px; }
.clear-search { display: grid; place-items: center; width: 30px; height: 30px; flex: 0 0 auto; margin-right: -4px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: #889381; }
.clear-search:hover { background: var(--page); }
.clear-search .icon { width: 15px; height: 15px; }
.systems { padding-top: 32px; scroll-margin-top: 20px; }
.section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.section-heading h2 { font-size: 15px; font-weight: 500; line-height: 22px; }
.section-heading p { color: var(--muted); font-size: 11px; line-height: 20px; }
.system-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.system-card { position: relative; display: flex; align-items: center; gap: 18px; min-width: 0; height: 140px; padding: 24px; border: 1px solid var(--border); border-radius: 13px; color: var(--ink); background: #fff; text-align: left; box-shadow: 0 2px 7px #20382a06, 0 5px 14px #20382a02; transition: transform .2s, border-color .2s, box-shadow .2s; }
.system-icon { display: grid; place-items: center; width: 56px; height: 56px; flex: 0 0 auto; border-radius: 16px; }
.system-icon .icon { width: 27px; height: 27px; stroke-width: 1.6; }
.system-icon--pr { color: #8f82a2; background: #f0ecf7; }
.system-icon--po { color: #7c9bb0; background: #eef3f9; }
.system-icon--hr { color: #b68b99; background: #faeef2; }
.system-icon--sale { color: #b59b66; background: #fbf4e6; }
.system-icon--store { color: #7c9e85; background: #eef5ec; }
.system-icon--rider { color: #8a99aa; background: #eef2f7; }
.system-copy { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.system-name { font-size: 24px; font-weight: 600; line-height: 31px; letter-spacing: -.9px; }
.system-description { color: #6e7965; font-size: 12px; line-height: 20px; }
.card-arrow { position: absolute; top: 26px; right: 25px; width: 14px; height: 14px; color: #a1a898; stroke-width: 1.3; transition: transform .2s, color .2s; }
@media (hover: hover) {
  .system-card:hover { transform: translateY(-3px); border-color: #bacab5; box-shadow: 0 7px 20px #20382a0a; }
  .system-card:hover .card-arrow { color: #617d5a; transform: translate(2px, -2px); }
}
.system-card:active { transform: translateY(0); background: #fcfdfb; }
.access-note { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 25px; color: var(--muted); font-size: 11px; line-height: 20px; }
.access-note .icon { width: 13px; height: 13px; stroke-width: 1.3; }
.empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 298px; padding: 32px 20px; border: 1px dashed #d7dfd0; border-radius: 13px; text-align: center; }
.empty-state-icon { display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 14px; border-radius: 50%; color: #8fa183; background: #eaf0e5; }
.empty-state h3 { font-size: 17px; font-weight: 500; }
.empty-state p { margin-top: 6px; color: var(--muted); font-size: 12px; }
.reset-search { margin-top: 18px; padding: 8px 14px; border: 1px solid #d2deca; border-radius: 7px; color: var(--forest); background: white; font-size: 12px; }
.reset-search:hover { background: #eef3e9; }
.noscript-note { margin-top: 24px; color: #64765e; font-size: 13px; text-align: center; }

.footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 59px; flex: 0 0 auto; border-top: 1px solid #dfe5d8; color: var(--muted); font-size: 9px; line-height: 16px; }

.system-dialog { position: fixed; width: min(380px, calc(100% - 40px)); max-height: calc(100svh - 40px); margin: auto; padding: 32px; overflow: auto; border: 1px solid var(--border); border-radius: 18px; color: var(--ink); background: #fff; text-align: center; box-shadow: 0 20px 80px #10261c26; }
.system-dialog::backdrop { background: #142f2766; backdrop-filter: blur(4px); }
.dialog-close { position: absolute; top: 14px; right: 14px; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 8px; color: #85917e; background: transparent; }
.dialog-close:hover { background: var(--page); }
.dialog-close .icon { width: 18px; height: 18px; }
.dialog-icon { margin: 0 auto 16px; }
.system-dialog h2 { font-size: 25px; font-weight: 600; letter-spacing: -.7px; }
.dialog-subtitle { margin-top: 2px; color: #6e7965; font-size: 12px; }
#dialog-description { margin-top: 22px; color: #69775f; font-size: 13px; line-height: 1.9; }
.dialog-confirm { width: 100%; margin-top: 26px; padding: 11px 20px; border: 1px solid var(--forest); border-radius: 8px; color: white; background: var(--forest); font-size: 13px; }
.dialog-confirm:hover { background: #2d604d; }

@media (max-width: 900px) {
  .system-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-orbit { left: 55%; }
  .system-card { gap: 16px; }
}

@media (max-width: 540px) {
  .container { width: calc(100% - 40px); }
  .hero { height: 276px; }
  .masthead { padding-top: 24px; }
  .brand { gap: 10px; }
  .brand-name { font-size: 17px; }
  .brand-subtitle { font-size: 7px; letter-spacing: 1.8px; }
  .brand-mark { width: 39px; height: 44px; }
  .workspace-label { display: none; }
  .welcome { margin-top: 39px; }
  .eyebrow { font-size: 8px; letter-spacing: 1.8px; }
  .welcome h1 { margin-top: 11px; font-size: clamp(25px, 6.9vw, 32px); letter-spacing: -.8px; }
  .company-name { margin-top: 7px; font-size: 12px; }
  .hero-orbit { top: 12px; left: 54%; width: 410px; height: 410px; border-width: 34px; }
  .hero-orbit::before { border-width: 34px; }
  .hero-orbit span { top: 71px; left: 71px; width: 5px; height: 5px; }
  .main-content { padding-bottom: 48px; }
  .search-box { gap: 10px; height: 54px; padding-inline: 15px; }
  .search-box input { font-size: 16px; }
  .search-box input::placeholder { font-size: 11px; }
  .search-shortcut { display: none; }
  .systems { padding-top: 27px; }
  .section-heading { gap: 10px; margin-bottom: 16px; }
  .section-heading p { font-size: 10px; }
  .system-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .system-card { height: 112px; padding: 22px; }
  .system-icon { width: 52px; height: 52px; border-radius: 15px; }
  .system-name { font-size: 22px; line-height: 29px; }
  .card-arrow { top: 23px; right: 22px; }
  .access-note { margin-top: 23px; font-size: 10px; }
  .footer { flex-wrap: wrap; justify-content: center; gap: 4px 20px; padding-block: 19px; font-size: 8px; text-align: center; }
}

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