:root {
  --leaf: #1f6f43;
  --leaf-deep: #0e3f2a;
  --mint: #dcefe3;
  --lime: #8bbf3d;
  --tomato: #d95d39;
  --grain: #f7f3ea;
  --cream: #fffcf4;
  --ink: #1d2a24;
  --muted: #62716a;
  --line: rgba(29, 42, 36, 0.14);
  --shadow: 0 22px 55px rgba(23, 43, 33, 0.16);
  --header-height: 78px;
  color-scheme: light;
  font-family: "Noto Sans TC", "Microsoft JhengHei", "PingFang TC", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.65;
}

body.modal-open {
  overflow: hidden;
}

body.modal-open::after {
  content: "";
  position: fixed;
  z-index: 40;
  inset: 0;
  background: rgba(5, 19, 13, 0.58);
  backdrop-filter: blur(5px);
}

body::selection {
  background: var(--lime);
  color: #102018;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  padding: 14px clamp(18px, 4vw, 54px);
  color: #fff;
  transition: background 180ms ease, box-shadow 180ms ease, color 180ms ease;
}

.site-header.is-scrolled,
.site-header.is-open {
  background: rgba(255, 252, 244, 0.94);
  color: var(--ink);
  box-shadow: 0 10px 30px rgba(11, 35, 24, 0.11);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-grid;
  grid-template-columns: 46px auto;
  align-items: center;
  gap: 12px;
  min-width: 178px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 46px;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 8px;
  background: #78be20;
  overflow: hidden;
  transition: all 180ms ease;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.is-scrolled .brand-mark,
.is-open .brand-mark {
  border-color: rgba(31, 111, 67, 0.2);
  background: #78be20;
}

.brand strong,
.brand small {
  display: block;
  line-height: 1.1;
}

.brand strong {
  font-size: 1.24rem;
  letter-spacing: 0;
}

.brand small {
  margin-top: 5px;
  font-size: 0.64rem;
  color: currentColor;
  opacity: 0.72;
  letter-spacing: 0.08em;
}

.site-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.4vw, 34px);
  font-weight: 700;
  font-size: 0.95rem;
}

.site-nav a {
  position: relative;
  padding: 8px 0;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 2px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
}

.header-login,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 0;
  border-radius: 8px;
  padding: 0 18px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease;
}

.header-login {
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.13);
  color: inherit;
}

.is-scrolled .header-login,
.is-open .header-login {
  border-color: rgba(31, 111, 67, 0.25);
  background: var(--leaf);
  color: #fff;
}

.button:hover,
.header-login:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--tomato);
  color: #fff;
  box-shadow: 0 15px 30px rgba(217, 93, 57, 0.26);
}

.button-glass {
  border: 1px solid rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  backdrop-filter: blur(12px);
}

.button-light {
  background: #fff;
  color: var(--leaf-deep);
}

.button-outline {
  border: 1px solid rgba(31, 111, 67, 0.3);
  background: transparent;
  color: var(--leaf-deep);
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
  box-shadow: none;
}

.nav-toggle {
  display: none;
  width: 46px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  padding: 10px;
}

.nav-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: currentColor;
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: #fff;
  isolation: isolate;
}

.hero-media,
.hero-media img,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-media {
  z-index: -2;
}

.hero-media img {
  height: 100%;
  object-fit: cover;
  object-position: center 54%;
}

.hero-overlay {
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(8, 39, 25, 0.88) 0%, rgba(8, 39, 25, 0.61) 42%, rgba(8, 39, 25, 0.18) 100%),
    linear-gradient(180deg, rgba(8, 39, 25, 0.2) 0%, rgba(8, 39, 25, 0.76) 100%);
}

.hero-content {
  width: min(1120px, calc(100% - 36px));
  margin: 0 auto;
  padding: calc(var(--header-height) + 76px) 0 190px;
}

.eyebrow {
  margin: 0 0 14px;
  color: #cde899;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow.dark {
  color: var(--leaf);
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.18;
  letter-spacing: 0;
}

h1 {
  max-width: 820px;
  font-size: clamp(4.2rem, 11vw, 9.4rem);
  font-weight: 900;
}

h2 {
  font-size: clamp(2.25rem, 4.6vw, 4.7rem);
}

h3 {
  font-size: 1.34rem;
}

.hero-copy {
  max-width: 620px;
  margin: 22px 0 30px;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  color: rgba(255, 255, 255, 0.88);
}

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

.hero-panel {
  position: absolute;
  left: 50%;
  bottom: 28px;
  width: min(1120px, calc(100% - 36px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
}

.hero-panel div {
  min-height: 128px;
  padding: 22px;
  border-right: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-panel div:last-child {
  border-right: 0;
}

.hero-panel span {
  color: #cde899;
  font-size: 0.8rem;
  font-weight: 900;
}

.hero-panel strong {
  display: block;
  margin-top: 8px;
  font-size: 1.16rem;
}

.hero-panel p {
  margin: 7px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.94rem;
}

.section {
  width: min(1120px, calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(76px, 9vw, 128px) 0;
}

.intro-band {
  width: 100%;
  background: var(--grain);
}

.section-grid {
  width: min(1120px, calc(100% - 36px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: clamp(28px, 6vw, 76px);
  align-items: center;
}

.section-grid p,
.section-heading p,
.about-copy > p,
.quality-copy p,
.contact-copy > p,
.portal-reserve p {
  color: var(--muted);
  font-size: 1.06rem;
}

.about {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(30px, 6vw, 72px);
  align-items: center;
}

.about-media {
  position: relative;
  min-height: 580px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.about-media img {
  height: 100%;
  object-fit: cover;
  object-position: 42% center;
}

.value-list {
  display: grid;
  gap: 14px;
  margin-top: 34px;
}

.value-list article,
.timeline article,
.admin-panel,
.contact-form,
.product-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.value-list article {
  padding: 22px;
}

.value-list p,
.timeline p,
.product-card p,
.admin-panel p,
.dialog-body p {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-heading {
  max-width: 720px;
  margin-bottom: 34px;
}

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

.product-card {
  overflow: hidden;
  box-shadow: 0 16px 38px rgba(23, 43, 33, 0.08);
}

.product-card img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.product-card div {
  padding: 22px;
}

.quality {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: clamp(30px, 6vw, 74px);
}

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

.timeline article {
  min-height: 198px;
  padding: 24px;
  background: linear-gradient(180deg, #fff 0%, #f7fbf2 100%);
}

.timeline span {
  display: inline-flex;
  margin-bottom: 16px;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--mint);
  color: var(--leaf-deep);
  font-size: 0.8rem;
  font-weight: 900;
}

.portal-reserve {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
  padding: clamp(46px, 7vw, 76px) clamp(18px, 6vw, 76px);
  background:
    linear-gradient(rgba(11, 63, 42, 0.84), rgba(11, 63, 42, 0.84)),
    url("assets/fuyu-fleet.jpg") center 62% / cover;
  color: #fff;
}

.portal-reserve h2,
.portal-reserve p {
  max-width: 820px;
}

.portal-reserve p {
  color: rgba(255, 255, 255, 0.8);
}

.contact {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  gap: clamp(28px, 6vw, 72px);
}

.admin-panel {
  margin-top: 30px;
  padding: 24px;
  background: var(--grain);
}

.admin-panel span {
  display: block;
  margin-top: 14px;
  color: var(--leaf-deep);
  font-weight: 800;
}

.contact-form {
  padding: clamp(22px, 4vw, 36px);
  box-shadow: var(--shadow);
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--leaf-deep);
  font-weight: 900;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(29, 42, 36, 0.18);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 13px 14px;
  outline: 0;
  transition: border 160ms ease, box-shadow 160ms ease;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--leaf);
  box-shadow: 0 0 0 4px rgba(31, 111, 67, 0.12);
}

.form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.form-footer p {
  margin: 0;
  color: var(--leaf-deep);
  font-weight: 800;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 34px clamp(18px, 4vw, 54px);
  background: #10261a;
  color: #fff;
}

.site-footer p {
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.66);
}

.site-footer a {
  color: #cde899;
  font-weight: 900;
}

.login-dialog {
  position: fixed;
  z-index: 50;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(520px, calc(100% - 32px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  color: var(--ink);
  box-shadow: var(--shadow);
}

.login-dialog[hidden] {
  display: none;
}

.dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 1.4rem;
  cursor: pointer;
}

.dialog-body {
  padding: 42px;
}

.dialog-logo {
  width: 72px;
  height: 72px;
  margin-bottom: 18px;
  border-radius: 8px;
  object-fit: cover;
}

.portal-preview {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 24px 0;
}

.portal-preview span {
  display: grid;
  place-items: center;
  min-height: 72px;
  border-radius: 8px;
  background: var(--mint);
  color: var(--leaf-deep);
  text-align: center;
  font-size: 0.88rem;
  font-weight: 900;
}

@media (max-width: 920px) {
  .site-header {
    grid-template-columns: auto auto;
  }

  .brand {
    min-width: 0;
  }

  .nav-toggle {
    display: block;
    justify-self: end;
    color: inherit;
  }

  .site-nav,
  .header-login {
    display: none;
  }

  .site-header.is-open .site-nav,
  .site-header.is-open .header-login {
    display: flex;
  }

  .site-header.is-open {
    grid-template-columns: 1fr auto;
    height: auto;
  }

  .site-header.is-open .site-nav {
    grid-column: 1 / -1;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px 0;
  }

  .site-header.is-open .site-nav a {
    padding: 10px 0;
  }

  .site-header.is-open .header-login {
    grid-column: 1 / -1;
    width: 100%;
  }

  .hero {
    min-height: 980px;
  }

  .hero-content {
    padding-bottom: 520px;
  }

  .hero-panel,
  .product-grid,
  .section-grid,
  .about,
  .quality,
  .contact {
    grid-template-columns: 1fr;
  }

  .hero-panel {
    bottom: 18px;
  }

  .hero-panel div {
    min-height: 94px;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  }

  .hero-panel div:last-child {
    border-bottom: 0;
  }

  .about-media {
    min-height: 420px;
  }

  .portal-reserve {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  :root {
    --header-height: 68px;
  }

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

  .brand {
    grid-template-columns: 40px auto;
  }

  .brand-mark {
    width: 40px;
  }

  .brand small {
    display: none;
  }

  .hero {
    min-height: 940px;
  }

  .hero-content {
    width: calc(100% - 32px);
    padding-bottom: 520px;
  }

  .hero-actions,
  .form-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-actions .button,
  .form-footer .button {
    width: 100%;
  }

  .section,
  .section-grid,
  .hero-panel {
    width: calc(100% - 32px);
  }

  .form-row,
  .timeline,
  .portal-preview {
    grid-template-columns: 1fr;
  }

  .about-media {
    min-height: 320px;
  }

  .contact-form,
  .dialog-body {
    padding: 24px;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
