/* ==========================================================================
   Daishin VN - Main CSS & Layout Architecture
   Based on Wireframe Specs + Clean Minimalist Engineering UI
   ========================================================================== */

:root {
  --ink: #1f2328;
  --mid: #57606a;
  --mut: #8c959f;
  --line: #d0d7de;
  --fill: #eaeef2;
  --fill-2: #f6f8fa;
  --page: #ffffff;
  --note: #fdfbe8;
  --note-line: #d9d0ae;
  --primary: #0969da;
  --primary-hover: #0858b9;
  --success-bg: #dafbe1;
  --success-text: #1a7f37;
  --success-border: #4ac26b;
  --danger-bg: #ffebe9;
  --danger-text: #cf222e;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #eef1f5;
  color: var(--ink);
  font: 15px/1.6 "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

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

/* ---------- prototype navigation bar (top indicator) ---------- */
.proto-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #181b20;
  color: #fff;
  padding: 8px 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
  align-items: center;
  font-size: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.proto-bar b {
  margin-right: 8px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #8c959f;
}
.proto-bar a {
  text-decoration: none;
  padding: 3px 8px;
  border: 1px solid #3b424e;
  border-radius: 4px;
  color: #d0d7de;
  white-space: nowrap;
  font-size: 11.5px;
  transition: all 0.15s ease;
}
.proto-bar a:hover {
  background: #2f3640;
  color: #fff;
  border-color: #57606a;
}
.proto-bar a.on {
  background: #ffffff;
  color: var(--ink);
  border-color: #ffffff;
  font-weight: 600;
}

/* ---------- page container frame ---------- */
.wf-frame {
  max-width: var(--max);
  margin: 20px auto 40px;
  background: var(--page);
  border: 1px solid var(--line);
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.wrap {
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- site header / footer ---------- */
.site-head {
  border-bottom: 1px solid var(--line);
  background: #ffffff;
  position: relative;
}
.site-head .row {
  max-width: 1020px;
  margin: 0 auto;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.logo {
  min-width: 130px;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: .04em;
  background: var(--fill-2);
  border: 1px dashed var(--line);
  line-height: 1.2;
}
.mainnav {
  display: flex;
  gap: 20px;
  align-items: center;
  font-size: 13.5px;
}
.mainnav a {
  text-decoration: none;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  color: var(--ink);
  transition: border-color 0.15s ease, color 0.15s ease;
}
.mainnav a:hover {
  border-color: var(--ink);
}
.mainnav a.on,
.mainnav a.current-menu-item,
.mainnav a.active {
  border-color: var(--ink);
  font-weight: 600;
}

.site-foot {
  border-top: 1px solid var(--line);
  background: var(--fill-2);
  margin-top: 56px;
  padding: 36px 0 22px;
  font-size: 13px;
  color: var(--mid);
}
.site-foot h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ink);
  margin: 0 0 10px;
  font-weight: 700;
}
.site-foot ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-foot li {
  margin-bottom: 6px;
}
.site-foot a:hover {
  color: var(--ink);
  text-decoration: underline;
}
.foot-bottom {
  border-top: 1px solid var(--line);
  margin-top: 24px;
  padding-top: 14px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 12px;
  color: var(--mut);
}

/* ---------- primitives & boxes ---------- */
.box {
  border: 1px dashed var(--line);
  background: var(--fill-2);
  color: var(--mid);
  padding: 16px;
  border-radius: 2px;
}
.ph {
  border: 1px solid var(--line);
  background:
    linear-gradient(to top right, transparent 49.6%, var(--line) 49.6%, var(--line) 50.4%, transparent 50.4%),
    linear-gradient(to bottom right, transparent 49.6%, var(--line) 49.6%, var(--line) 50.4%, transparent 50.4%),
    var(--fill);
  color: var(--mid);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  letter-spacing: .04em;
  text-align: center;
  padding: 12px;
  text-transform: uppercase;
  font-weight: 600;
}
.btn {
  display: inline-block;
  border: 1px solid var(--ink);
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  background: #fff;
  white-space: nowrap;
  cursor: pointer;
  border-radius: 3px;
  transition: all 0.15s ease;
}
.btn-primary {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.btn-primary:hover {
  background: #333a42;
  color: #fff;
}
.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}
.btn:hover {
  opacity: .88;
}

.lines > i {
  display: block;
  height: 9px;
  background: var(--fill);
  margin-bottom: 8px;
  font-style: normal;
  border-radius: 2px;
}
.lines > i:nth-child(3n) { width: 88%; }
.lines > i:last-child { width: 62%; }

h1 { font-size: 28px; line-height: 1.3; margin: 0 0 14px; color: var(--ink); font-weight: 700; }
h2 { font-size: 20px; margin: 0 0 8px; color: var(--ink); font-weight: 700; }
h3 { font-size: 15px; margin: 0 0 6px; color: var(--ink); font-weight: 600; }
.sec { padding: 44px 0 0; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.eyebrow { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--mut); margin: 0 0 6px; font-weight: 600; }
.mut { color: var(--mut); font-weight: 400; }
.lead { color: var(--mid); font-size: 15px; max-width: 65ch; line-height: 1.6; }

/* Grid layouts */
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: 1fr 1fr; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.g5 { grid-template-columns: repeat(5, 1fr); }
.split { display: grid; grid-template-columns: 250px 1fr; gap: 32px; }
.split-r { display: grid; grid-template-columns: 1fr 320px; gap: 32px; }

/* ---------- job cards & rows ---------- */
.card {
  border: 1px solid var(--line);
  padding: 18px;
  background: #fff;
  text-decoration: none;
  display: block;
  transition: all 0.15s ease;
}
a.card:hover {
  background: var(--fill-2);
  border-color: #abb2bf;
}
.card h3 { font-size: 15.5px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; }
.tag {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 11.5px;
  color: var(--mid);
  background: var(--fill-2);
  white-space: nowrap;
}
.meta { font-size: 12.5px; color: var(--mid); margin: 6px 0 0; }
.pay { font-weight: 700; font-size: 15.5px; color: var(--ink); }

.joblist { display: grid; gap: 12px; }
.jobrow {
  border: 1px solid var(--line);
  padding: 18px 20px;
  display: grid;
  grid-template-columns: 1fr 160px;
  gap: 18px;
  align-items: center;
  text-decoration: none;
  background: #fff;
  transition: all 0.15s ease;
}
.jobrow:hover {
  background: var(--fill-2);
  border-color: #abb2bf;
}

/* ---------- form controls ---------- */
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.field .in,
.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="number"],
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--fill-2);
  padding: 9px 12px;
  font-size: 13.5px;
  font-family: inherit;
  color: var(--ink);
  border-radius: 3px;
  outline: none;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--ink);
  background: #fff;
}
.field textarea {
  min-height: 96px;
  resize: vertical;
}
.field .in.file {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  color: var(--mut);
  font-size: 12.5px;
  background: var(--fill-2);
  border: 1px dashed var(--line);
}
.req { color: #cf222e; }
.hint { font-size: 11.5px; color: var(--mut); margin-top: 5px; }

/* Alert boxes */
.alert {
  padding: 14px 18px;
  border-radius: 4px;
  margin-bottom: 20px;
  font-size: 13.5px;
}
.alert-success {
  background: var(--success-bg);
  color: var(--success-text);
  border: 1px solid var(--success-border);
}
.alert-error {
  background: var(--danger-bg);
  color: var(--danger-text);
  border: 1px solid #ff8182;
}

/* ---------- timeline (Làm việc tại Nhật) ---------- */
.tl {
  border-left: 2px solid var(--line);
  margin-left: 14px;
  padding-left: 28px;
}
.tl-step {
  position: relative;
  padding-bottom: 28px;
}
.tl-step:last-child {
  padding-bottom: 0;
}
.tl-step::before {
  content: "";
  position: absolute;
  left: -37px;
  top: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid var(--ink);
}
.tl-step .step-n {
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--mut);
  text-transform: uppercase;
  font-weight: 700;
  margin: 0 0 4px;
}

/* Accordion */
.faq-item {
  border: 1px solid var(--line);
  margin-bottom: 10px;
  background: #fff;
}
.faq-trigger {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 16px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  color: var(--ink);
}
.faq-trigger:hover {
  background: var(--fill-2);
}
.faq-body {
  display: none;
  padding: 0 18px 16px;
  font-size: 13.5px;
  color: var(--mid);
  line-height: 1.6;
}
.faq-item.open .faq-body {
  display: block;
}
.faq-icon {
  font-size: 18px;
  font-weight: bold;
}

/* Responsive */
@media (max-width: 900px) {
  .g4, .g3, .g5 { grid-template-columns: repeat(2, 1fr); }
  .split, .split-r { grid-template-columns: 1fr; }
  .jobrow { grid-template-columns: 1fr; }
  .wf-frame { margin: 0; border: none; }
  .site-head .row { flex-direction: column; align-items: flex-start; }
  .mainnav { flex-wrap: wrap; gap: 10px 14px; width: 100%; }
}
@media (max-width: 600px) {
  .g2, .g4, .g3, .g5 { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px; }
  .foot-bottom { flex-direction: column; }
}
