/* ==================== RESET & VARIABLES ==================== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-gold: #CBAB35;
  --color-gold-light: #ffecab;
  --color-gold-deep: #8a7420;
  --color-main: #473b14;
  --color-text: #464646;
  --color-link: #687CE4;
  --color-bg: #F7F7F7;
  --color-white: #ffffff;
  --color-border: #EEEEEE;
  --color-bar: #E5DBB9;
  --color-sepia: #E5DBB9;
  --color-tag: #687CE4;
  --color-header: #222222;
  --font-serif: 'Noto Serif JP', serif;
  --font-sans: 'Noto Sans JP', sans-serif;
  --gold-gradient: linear-gradient(135deg, #CBAB35, #d4b942);
  --gold-text-gradient: linear-gradient(135deg, #CBAB35 0%, #e8c84a 50%, #CBAB35 100%);
}

/* ==================== BASE STYLES ==================== */
html {
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

ul, li {
  list-style: none;
}

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

input, select, button {
  font-family: inherit;
}

/* ==================== GOLD TEXT UTILITY ==================== */
.gold-text {
  background: var(--gold-text-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ==================== HEADER: 1-ROW (jobs / article pages) ==================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-header);
  border-top: 2px solid transparent;
  border-image: linear-gradient(90deg, var(--color-gold), var(--color-gold-light), var(--color-gold)) 1;
}

.header-inner {
  max-width: 1440px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  height: 50px;
}

.header-brand {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-shrink: 0;
}

.header-logo {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--color-gold), var(--color-gold-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.header-tagline {
  font-size: 11px;
  color: #999;
  white-space: nowrap;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.header-nav a {
  font-size: 13px;
  color: #ccc;
  transition: color 0.2s;
  white-space: nowrap;
  position: relative;
}

.header-nav a:hover {
  color: #fff;
}

.header-nav a.active {
  color: var(--color-gold);
}

.header-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -20px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-gold);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.header-search-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #ccc;
  padding: 4px;
  display: flex;
  align-items: center;
}

.header-search-btn:hover {
  color: #fff;
}

.header-post-btn {
  font-size: 12px;
  color: #ccc;
  border: 1px solid #666;
  padding: 6px 16px;
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.header-post-btn:hover {
  border-color: var(--color-gold);
  color: var(--color-gold);
}

.btn-school {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 24px;
  background: linear-gradient(135deg, #CBAB35, #d4b942);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font-sans);
  border-radius: 4px;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: opacity 0.2s, box-shadow 0.2s;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(203, 171, 53, 0.3);
}

.btn-school:hover {
  opacity: 0.92;
  box-shadow: 0 4px 12px rgba(203, 171, 53, 0.45);
}

/* ==================== HEADER: 2-ROW (TOP page only) ==================== */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-row1 {
  background: var(--color-header);
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  border-top: 2px solid transparent;
  border-image: linear-gradient(90deg, #CBAB35, #ffecab, #CBAB35) 1;
}

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

.header-logo-text {
  font-family: 'Noto Serif JP', serif;
  font-size: 20px;
  font-weight: 700;
  background: linear-gradient(135deg, #CBAB35, #ffecab, #CBAB35);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.header-logo-tagline {
  font-size: 11px;
  color: #aaa;
  white-space: nowrap;
}

.header-center {
  display: flex;
  align-items: center;
  gap: 24px;
}

.header-center a {
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}

.header-center a:hover {
  color: var(--color-gold);
}

.header-center a.active {
  color: var(--color-gold);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn-gold-hex {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 28px;
  background: linear-gradient(135deg, #CBAB35, #d4b942);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: opacity 0.2s, box-shadow 0.2s;
  letter-spacing: 0.06em;
  box-shadow: 0 2px 8px rgba(203, 171, 53, 0.3);
  white-space: nowrap;
}

.btn-gold-hex:hover {
  opacity: 0.92;
  box-shadow: 0 4px 12px rgba(203, 171, 53, 0.45);
}

.btn-dark {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 18px;
  background: #444;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid #555;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.btn-dark:hover {
  background: #555;
}

.header-text-link {
  color: #aaa;
  font-size: 12px;
  transition: color 0.2s;
}

.header-text-link:hover {
  color: #fff;
}

.header-row2 {
  background: var(--color-white);
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 40px;
  border-bottom: 1px solid var(--color-border);
}

/* TOP header nav (row2) */
.header-row2 .header-nav {
  display: flex;
  align-items: center;
  gap: 0;
}

.header-row2 .header-nav a {
  font-size: 13px;
  color: var(--color-text);
  padding: 10px 16px;
  position: relative;
  transition: color 0.2s;
  white-space: nowrap;
}

.header-row2 .header-nav a:hover {
  color: var(--color-gold-deep);
}

.header-row2 .header-nav a.active {
  color: var(--color-gold-deep);
  font-weight: 700;
}

.header-row2 .header-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 16px;
  right: 16px;
  height: 2px;
  background: var(--color-gold);
  border-radius: 1px;
}

.search-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  cursor: pointer;
  background: none;
  transition: border-color 0.2s, background 0.2s;
}

.search-btn:hover {
  border-color: #ccc;
  background: #fafafa;
}

.search-btn svg {
  width: 16px;
  height: 16px;
  color: #888;
}

/* ==================== FOOTER ==================== */
.site-footer {
  background: #1a1a1a;
  color: #999;
  padding: 48px 40px 0;
}

.footer-inner {
  max-width: 1440px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 40px;
}

.footer-brand-logo {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--color-gold), var(--color-gold-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 10px;
}

.footer-brand-desc {
  font-size: 12px;
  line-height: 1.6;
  margin-bottom: 14px;
  color: #888;
}

.footer-col-title {
  font-family: var(--font-serif);
  font-size: 13px;
  font-weight: 700;
  color: #ccc;
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: none;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a {
  font-size: 13px;
  color: #888;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--color-gold);
}

.footer-bottom {
  border-top: 1px solid #222;
  padding: 16px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1440px;
  margin: 0 auto;
}

.footer-copy {
  font-size: 11px;
  color: #666;
}

.footer-note {
  font-size: 11px;
  color: #555;
}

/* ==================== POPULAR KEYWORDS SECTION ==================== */
.keywords-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px;
  text-align: center;
}

.keywords-title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-main);
  margin-bottom: 20px;
}

.keywords-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.keyword-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 16px;
  background: var(--color-white);
  border: 1px solid var(--color-sepia);
  border-radius: 0;
  font-size: 13px;
  color: var(--color-main);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.keyword-tag:hover {
  border-color: var(--color-gold);
  background: #fafaf6;
}

.keyword-tag .hash {
  color: var(--color-gold);
  font-weight: 700;
}

.keywords-title-diamond {
  color: var(--color-gold);
  font-size: 12px;
}

/* ==================== RESPONSIVE: max-width 768px ==================== */
@media (max-width: 768px) {

  /* ── HEADER 1-ROW (site-header) mobile ── */
  .header-inner {
    padding: 0 16px;
    height: 56px;
  }

  .header-tagline {
    display: none;
  }

  .header-nav {
    display: none;
  }

  .header-right {
    gap: 10px;
  }

  .btn-school {
    padding: 7px 14px;
    font-size: 12px;
  }

  .header-post-btn {
    display: none;
  }

  /* ── HEADER 2-ROW (TOP) mobile ── */
  .header-row1 {
    padding: 0 16px;
    height: 56px;
  }

  .header-logo-tagline {
    display: none;
  }

  .header-row2 {
    overflow-x: auto;
    padding: 0 16px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .header-row2::-webkit-scrollbar {
    display: none;
  }

  .header-row2 .header-nav {
    gap: 16px;
    font-size: 12px;
    white-space: nowrap;
  }

  .header-row2 .header-nav a {
    font-size: 12px;
    white-space: nowrap;
    padding: 10px 8px;
  }

  /* ── FOOTER mobile ── */
  .site-footer {
    padding: 36px 20px 0;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  /* ── KEYWORDS SECTION mobile ── */
  .keywords-section {
    padding: 32px 16px;
  }

  .keyword-tag {
    font-size: 12px;
    padding: 6px 12px;
  }
}

/* ==================== RESPONSIVE: max-width 960px ==================== */
@media (max-width: 960px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* === 共通ヘッダー(非TOP)ナビ色: 白→金 === */
.site-header .header-nav a { color: #fff !important; }
.site-header .header-nav a:hover { color: var(--color-gold) !important; }
.site-header .header-nav a.active { color: var(--color-gold) !important; font-weight: 700; }
.site-header .header-nav a.active::after { background: var(--color-gold); }
