@charset "utf-8";

/*
  Noshiro Design Tokens + Components
  - Tokens are defined in :root so any page can reuse them.
  - Component classes are generic (e.g. .btn, .card). If you need namespacing,
    we can add a prefix pass later.
*/

/* -----------------------------
 * Design tokens
 * ----------------------------- */
:root {
  /* Color tokens (derived from recruit CSS usage) */
  --color-brand-1: #22ac38; /* CTA / Primary */
  --color-brand-1-hover: #1f8134;
  --color-sub-1: #004ea2; /* Secondary blue */
  --color-sub-1-border: #39a1ff;
  --color-link: #00a0e9;

  --gray-0: #ffffff;
  --gray-50: #fbfff8;
  --gray-100: #f5f5f5;
  --gray-150: #f3f3f3;
  --gray-200: #ededed;
  --gray-250: #e5e5e5;
  --gray-300: #cccccc;
  --gray-350: #c3c0c0;
  --gray-400: #9f9f9f;
  --gray-500: #707070;
  --gray-600: #606060;
  --gray-700: #3f3f3f;
  --gray-800: #333333;
  --gray-900: #001e3c; /* used in form */

  --color-text: var(--gray-800);
  --color-text-strong: var(--gray-900);
  --color-surface: var(--gray-0);
  --color-border: var(--gray-300);
  --color-border-muted: var(--gray-250);

  --color-danger: #ff0000;
  --color-danger-bg: #ffeeee;

  /* Typography tokens */
  --font-sans: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", system-ui, -apple-system, "BIZ UDPGothic",
    "YuGothic", "メイリオ", meiryo, sans-serif;
  --font-display: "Saira", sans-serif;

  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  --lh-tight: 1.2;
  --lh-snug: 1.33;
  --lh-base: 1.5;
  --lh-body: 2;

  /* Font sizes (px so they don't depend on 1rem=10px) */
  --fs-12: 12px;
  --fs-14: 14px;
  --fs-16: 16px;
  --fs-18: 18px;
  --fs-22: 22px;
  --fs-24: 24px;
  --fs-28: 28px;
  --fs-32: 32px;
  --fs-36: 36px;
  --fs-40: 40px;
  --fs-50: 50px;
  --fs-72: 72px;

  /* Spacing tokens (8px base) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 32px;
  --space-8: 40px;
  --space-9: 48px;
  --space-10: 56px;
  --space-11: 64px;
  --space-12: 80px;
  --space-13: 96px;

  /* Radius / Shadow */
  --radius-4: 4px;
  --radius-5: 5px; /* form control */
  --radius-6: 6px;
  --radius-10: 10px;
  --radius-12: 12px;
  --radius-pill: 9999px;

  --shadow-0: none;
  --shadow-1: 0 12px 13px rgba(169, 182, 183, 0.6);

  --focus-ring: 0 0 0 3px rgba(57, 161, 255, 0.35);
}

/* -----------------------------
 * Utilities
 * ----------------------------- */
.gf {
  font-family: var(--font-display);
}

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

.stack {
  display: grid;
  gap: var(--space-4);
}

/* -----------------------------
 * Component: Buttons
 * ----------------------------- */
.btn-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.btn {
  appearance: none;
  border: 1px solid transparent;
  border-radius: var(--radius-12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  height: 52px;
  font-size: var(--fs-16);
  font-weight: var(--fw-semibold);
  line-height: 1;
  cursor: pointer;
  transition: transform 0.05s ease, opacity 140ms ease, background-color 140ms ease, border-color 140ms ease;
  user-select: none;
}

.btn:hover {
  opacity: 0.7;
}

.btn:active {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.btn.primary {
  background: var(--color-brand-1);
  color: var(--gray-0);
}

.btn.primary:hover {
  background: var(--color-brand-1-hover);
}

.btn.secondary {
  background: var(--color-sub-1);
  color: var(--gray-0);
}

.btn.outline {
  background: var(--gray-0);
  color: var(--color-sub-1);
  border-color: var(--color-sub-1-border);
}

.btn.ghost {
  background: transparent;
  color: var(--color-text-strong);
  border-color: var(--color-border-muted);
}

.btn.sm {
  height: 40px;
  border-radius: var(--radius-10);
  font-size: var(--fs-14);
  padding: 0 14px;
}

.btn.lg {
  height: 60px;
  border-radius: var(--radius-12);
  font-size: var(--fs-18);
  padding: 0 22px;
}

/* -----------------------------
 * Component: Card
 * ----------------------------- */
.card {
  overflow: hidden;
  border-radius: var(--radius-12);
  border: 1px solid var(--color-border-muted);
  background: var(--gray-0);
  box-shadow: var(--shadow-1);
}

.card .media {
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, rgba(0, 160, 233, 0.25), rgba(34, 172, 56, 0.25));
}

.card .body {
  padding: var(--space-6);
}

.card .kicker {
  font-family: var(--font-display);
  letter-spacing: 0.08em;
  font-size: var(--fs-14);
  color: var(--gray-600);
  margin: 0 0 var(--space-2);
}

.card h3 {
  margin: 0 0 var(--space-2);
  font-size: var(--fs-22);
  line-height: var(--lh-snug);
  font-weight: var(--fw-bold);
}

.card p {
  margin: 0;
  color: var(--gray-600);
  font-size: var(--fs-14);
  line-height: 1.8;
}

/* -----------------------------
 * Component: News list
 * ----------------------------- */
.news {
  display: grid;
  gap: 10px;
}

.news-item {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 14px;
  align-items: center;
  padding: 14px 14px;
  border: 1px solid var(--color-border-muted);
  border-radius: var(--radius-10);
  background: var(--gray-0);
  color: inherit;
  text-decoration: none;
  transition: opacity 140ms ease;
}

a.news-item:hover {
  opacity: 0.7;
}

@media (max-width: 600px) {
  .news-item {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

.news-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.news-date {
  font-family: var(--font-display);
  font-size: var(--fs-14);
  color: var(--gray-600);
  letter-spacing: 0.04em;
}

.tag {
  display: inline-block;
  font-size: var(--fs-12);
  font-weight: var(--fw-semibold);
  color: var(--gray-0);
  background: var(--color-link);
  border-radius: var(--radius-6);
  padding: 4px 8px;
  line-height: 1;
  width: fit-content;
}

.tag.green {
  background: #8fc31f;
}

.news-title {
  font-size: var(--fs-16);
  font-weight: var(--fw-bold);
  line-height: var(--lh-base);
}

.news-title,
.news-title a {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.news-title a {
  color: inherit;
}

/* -----------------------------
 * Component: Form
 * ----------------------------- */
.form {
  display: grid;
  gap: var(--space-6);
}

.field {
  display: grid;
  gap: 8px;
}

.label-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  justify-content: space-between;
}

.req {
  font-size: var(--fs-12);
  font-weight: var(--fw-bold);
  color: var(--gray-0);
  background: var(--color-danger);
  border-radius: var(--radius-pill);
  padding: 4px 8px;
  line-height: 1;
}

.help {
  font-size: var(--fs-14);
  color: var(--gray-600);
  line-height: 1.6;
}

.control {
  width: 100%;
  max-width: 769px;
  height: 60px;
  border: 1px solid var(--gray-350);
  border-radius: var(--radius-5);
  background: var(--gray-0);
  padding: 0 1em 0 1.2em;
  font-size: var(--fs-16);
  line-height: var(--lh-base);
  color: var(--gray-800);
  font-family: var(--font-sans);
}

.control::placeholder {
  color: var(--gray-400);
}

.control:focus {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--color-sub-1-border);
}

textarea.control {
  height: auto;
  min-height: 160px;
  padding: 1em 1.2em;
  resize: vertical;
}

.control.error {
  border-color: var(--color-danger);
}

.error-box {
  border-radius: var(--radius-12);
  background: var(--color-danger-bg);
  border: 1px solid var(--color-danger);
  padding: 14px 18px;
  font-weight: var(--fw-bold);
  color: var(--color-danger);
  font-size: var(--fs-14);
  line-height: 1.6;
}

/* -----------------------------
 * Component: Breadcrumb
 * ----------------------------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: var(--fs-14);
  line-height: var(--lh-base);
}

.breadcrumb a {
  color: var(--color-link);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.breadcrumb .sep {
  color: var(--gray-500);
}

/* -----------------------------
 * Component: Header / Footer
 * ----------------------------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  padding: var(--space-5);
  border-radius: var(--radius-12);
  border: 1px solid var(--color-border-muted);
  background: var(--gray-0);
  overflow: visible;
  position: relative;
  font-family: var(--font-sans);
}

.site-header .logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-header .logo img {
  width: 160px;
  height: auto;
}

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

.site-menu-button {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-10);
  border: 1px solid var(--color-border-muted);
  background: var(--gray-0);
  cursor: pointer;
  transition: opacity 140ms ease, background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.site-menu-button:hover {
  opacity: 0.7;
  background: var(--gray-100);
}

.site-menu-button:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.hamburger {
  display: grid;
  gap: 5px;
}

.hamburger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--gray-700);
  border-radius: var(--radius-pill);
}

.site-nav-panel {
  display: block;
}

.site-nav-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  justify-content: flex-end;
  flex: 1 1 auto;
}

.site-nav-aux {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
}

.site-nav-aux > li {
  position: relative;
}

.site-nav-aux .aux-link {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: var(--radius-10);
  font-family: var(--font-sans);
  font-size: var(--fs-14);
  font-weight: var(--fw-bold);
  color: var(--color-text);
}

.site-nav-aux .aux-link:hover {
  opacity: 1;
  background: var(--gray-100);
}

.site-nav {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
}

.site-nav > li {
  position: relative;
}

.site-nav .nav-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 10px;
  border-radius: var(--radius-10);
  font-family: var(--font-sans);
  font-weight: var(--fw-bold);
  font-size: var(--fs-14);
  color: var(--color-text);
}

.site-nav button.nav-link {
  appearance: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  text-align: left;
}

.site-nav .nav-link:hover {
  opacity: 1;
  background: var(--gray-100);
}

.site-nav .dropdown-toggle::after {
  content: "";
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--gray-600);
  transform: translateY(1px);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 220px;
  background: var(--gray-0);
  border: 1px solid var(--color-border-muted);
  border-radius: var(--radius-12);
  box-shadow: var(--shadow-1);
  padding: 10px;
  display: none;
  z-index: 20;
}

.dropdown-menu::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -8px;
  height: 8px;
}

.dropdown-menu a {
  display: block;
  padding: 10px 10px;
  border-radius: var(--radius-10);
  font-family: var(--font-sans);
  font-size: var(--fs-14);
  font-weight: var(--fw-bold);
  color: var(--color-text);
  line-height: var(--lh-base);
}

.dropdown-menu a:hover {
  opacity: 1;
  background: var(--gray-100);
}

.site-nav li.dropdown.open .dropdown-menu {
  display: block;
}

@media (max-width: 768px) {
  .site-menu-button {
    display: inline-flex;
  }

  .site-nav-panel {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background: var(--gray-0);
    border: 1px solid var(--color-border-muted);
    border-radius: var(--radius-12);
    box-shadow: var(--shadow-1);
    padding: 12px;
    z-index: 30;
  }

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

  .site-nav-wrap {
    align-items: stretch;
    gap: 10px;
  }

  /* Mobile menu order: main nav first, then aux (下段→上段の順) */
  .site-nav {
    order: 1;
  }

  .site-nav-aux {
    order: 2;
  }

  .site-nav-aux,
  .site-nav {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
  }

  .site-nav-aux .aux-link,
  .site-nav .nav-link {
    justify-content: space-between;
    padding: 12px 12px;
  }

  /* Mobile dropdown becomes in-flow accordion */
  .dropdown-menu {
    position: static;
    top: auto;
    left: auto;
    min-width: 0;
    border: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: var(--shadow-0);
    padding: 0;
    margin-top: 6px;
    margin-left: 12px;
  }

  .dropdown-menu a {
    position: relative;
    padding: 10px 12px 10px 26px;
    font-family: var(--font-sans);
    font-size: var(--fs-14);
    font-weight: var(--fw-bold);
  }

  .dropdown-menu a::before {
    content: "・";
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-500);
  }

  .site-nav li.dropdown .dropdown-menu {
    display: none;
  }

  .site-nav li.dropdown.open .dropdown-menu {
    display: block;
  }

  .dropdown-menu::before {
    display: none;
  }

  .site-nav .dropdown-toggle::after {
    border-top-color: var(--gray-500);
    transition: transform 0.15s ease;
  }

  .site-nav li.dropdown.open .dropdown-toggle::after {
    transform: rotate(180deg) translateY(-1px);
  }

  /* Disable hover-open on touch layouts (keep open state visible) */
  .site-nav li.dropdown:not(.open):hover .dropdown-menu {
    display: none;
  }
}

.site-footer {
  border-radius: var(--radius-12);
  background: var(--gray-900);
  color: var(--gray-0);
  padding: var(--space-7);
  font-family: var(--font-sans);
}

.site-footer .cols {
  display: grid;
  gap: var(--space-6);
}

@media (min-width: 900px) {
  .site-footer .cols {
    grid-template-columns: 1.2fr 1fr 1fr;
    align-items: start;
  }
}

.site-footer .brandline {
  font-family: var(--font-display);
  letter-spacing: 0.08em;
  font-weight: var(--fw-semibold);
}

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

.site-footer a {
  color: rgba(255, 255, 255, 0.9);
}

.site-footer small {
  display: block;
  margin-top: var(--space-6);
  color: rgba(255, 255, 255, 0.7);
}
