/* ===========================
   CSS Variables & Reset
   =========================== */
:root {
  --primary: #1a56db;
  --primary-dark: #1444b0;
  --primary-light: #e8effc;
  --accent: #2563eb;
  --text: #1e293b;
  --text-light: #64748b;
  --text-lighter: #94a3b8;
  --bg: #ffffff;
  --bg-gray: #f8fafc;
  --border: #e2e8f0;
  --white: #ffffff;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 32px rgba(0,0,0,0.1);
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-ja: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', sans-serif;
  --font-en: 'Inter', sans-serif;
  --max-width: 1100px;
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-ja);
  color: var(--text);
  background: var(--bg);
  line-height: 1.8;
  overflow-x: hidden;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--primary-dark);
}

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

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.pc-only {
  display: none;
}

@media (min-width: 768px) {
  .pc-only { display: inline; }
}

/* ===========================
   Header
   =========================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.header--scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.header__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.header__logo {
  font-family: var(--font-en);
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.header__logo-img {
  height: 32px;
  width: auto;
  display: block;
}

.footer__logo-img {
  height: 28px;
  width: auto;
  display: block;
}

.header__hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 1001;
}

.header__hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
  transition: var(--transition);
}

.header__hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.header__hamburger.active span:nth-child(2) {
  opacity: 0;
}

.header__hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.header__nav {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(255,255,255,0.98);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}

.header__nav.active {
  display: flex;
}

.header__nav-link {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  transition: color var(--transition);
}

.header__nav-link:hover {
  color: var(--primary);
}

.header__nav-link--cta {
  background: var(--primary);
  color: var(--white) !important;
  padding: 10px 28px;
  border-radius: 50px;
  font-size: 0.95rem;
}

.header__nav-link--cta:hover {
  background: var(--primary-dark);
  color: var(--white) !important;
}

@media (min-width: 768px) {
  .header__hamburger {
    display: none;
  }

  .header__nav {
    display: flex;
    position: static;
    width: auto;
    height: auto;
    background: none;
    flex-direction: row;
    gap: 32px;
  }

  .header__nav-link {
    font-size: 0.9rem;
  }
}

/* ===========================
   Buttons
   =========================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 36px;
  border-radius: 50px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: var(--font-ja);
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
}

.btn--primary {
  background: var(--primary);
  color: var(--white);
  box-shadow: 0 4px 16px rgba(26,86,219,0.3);
}

.btn--primary:hover {
  background: var(--primary-dark);
  color: var(--white);
  box-shadow: 0 6px 24px rgba(26,86,219,0.4);
  transform: translateY(-1px);
}

.btn--outline {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255,255,255,0.6);
}

.btn--outline:hover {
  background: rgba(255,255,255,0.1);
  color: var(--white);
  border-color: var(--white);
}

.btn--large {
  padding: 16px 48px;
  font-size: 1rem;
}

/* ===========================
   Hero
   =========================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #0f2555 0%, #1a56db 50%, #2563eb 100%);
  z-index: 0;
}

.hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 70% 20%, rgba(255,255,255,0.08) 0%, transparent 100%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(255,255,255,0.05) 0%, transparent 100%);
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 120px 24px 80px;
  max-width: 800px;
}

.hero__subtitle {
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
  letter-spacing: 0.12em;
  margin-bottom: 16px;
  font-family: var(--font-en);
}

.hero__title {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--white);
  line-height: 1.4;
  margin-bottom: 24px;
  letter-spacing: 0.02em;
}

.hero__highlight {
  background: linear-gradient(to right, #60a5fa, #93c5fd);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero__desc {
  font-size: 1rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.9;
  margin-bottom: 40px;
}

.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
}

@media (min-width: 768px) {
  .hero__title {
    font-size: 3.2rem;
  }

  .hero__desc {
    font-size: 1.1rem;
  }

  .hero__actions {
    flex-direction: row;
    justify-content: center;
  }
}

/* ===========================
   Section Common
   =========================== */
.section {
  padding: 96px 0;
}

.section--gray {
  background: var(--bg-gray);
}

.section__header {
  text-align: center;
  margin-bottom: 56px;
}

.section__label {
  font-family: var(--font-en);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.section__title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
}

.section__desc {
  font-size: 1rem;
  color: var(--text-light);
  max-width: 560px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .section__title {
    font-size: 2.2rem;
  }
}

/* ===========================
   Services
   =========================== */
.services {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .services {
    grid-template-columns: repeat(3, 1fr);
  }
}

.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px 28px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: all var(--transition);
}

.service-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.service-card__icon {
  width: 56px;
  height: 56px;
  color: var(--primary);
  margin-bottom: 20px;
}

.service-card__icon svg {
  width: 100%;
  height: 100%;
}

.service-card__title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text);
}

.service-card__desc {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 16px;
}

.service-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* Tags */
.tag {
  display: inline-block;
  padding: 4px 12px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 500;
}

.tag--small {
  padding: 3px 10px;
  font-size: 0.7rem;
}

/* ===========================
   Works
   =========================== */
.works {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .works {
    grid-template-columns: repeat(2, 1fr);
  }
}

.work-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: all var(--transition);
  position: relative;
}

.work-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.work-card--wip {
  opacity: 0.85;
}

.work-card__badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--primary);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 50px;
  font-family: var(--font-en);
}

.work-card__badge--wip {
  background: var(--text-lighter);
}

.work-card__body {
  padding: 32px 28px;
}

.work-card__title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.work-card__subtitle {
  font-size: 0.85rem;
  color: var(--primary);
  font-weight: 500;
  margin-bottom: 12px;
}

.work-card__desc {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 16px;
}

.work-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.work-card__link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--primary);
  transition: color var(--transition);
}

.work-card__link:hover {
  color: var(--primary-dark);
}

.work-card__link--soon {
  color: var(--text-lighter);
  font-style: italic;
}

/* ===========================
   Company
   =========================== */
.company {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

@media (min-width: 768px) {
  .company {
    grid-template-columns: 1.2fr 1fr;
    align-items: start;
  }
}

.company__table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.company__table th,
.company__table td {
  padding: 16px 20px;
  text-align: left;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.company__table tr:last-child th,
.company__table tr:last-child td {
  border-bottom: none;
}

.company__table th {
  width: 140px;
  font-weight: 600;
  color: var(--text);
  background: var(--bg-gray);
  white-space: nowrap;
}

.company__table td {
  color: var(--text-light);
}

.company__table td a {
  color: var(--primary);
}

.company__map {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.company__map iframe {
  display: block;
}

/* ===========================
   Contact Form
   =========================== */
.contact-form {
  max-width: 640px;
  margin: 0 auto;
}

.contact-form__group {
  margin-bottom: 24px;
}

.contact-form__label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.required {
  color: #ef4444;
  font-size: 0.8rem;
}

.contact-form__input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-family: var(--font-ja);
  color: var(--text);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
  -webkit-appearance: none;
}

.contact-form__input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(26,86,219,0.12);
}

.contact-form__input::placeholder {
  color: var(--text-lighter);
}

.contact-form__textarea {
  resize: vertical;
  min-height: 140px;
}

select.contact-form__input {
  cursor: pointer;
}

.contact-form__group--privacy {
  margin-top: 8px;
}

.contact-form__checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.88rem;
  color: var(--text-light);
}

.contact-form__checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
  cursor: pointer;
  flex-shrink: 0;
}

.contact-form__submit {
  text-align: center;
  margin-top: 32px;
}

.contact-form__status {
  text-align: center;
  margin-top: 16px;
  font-size: 0.9rem;
  min-height: 1.5em;
}

.contact-form__status--success {
  color: #16a34a;
}

.contact-form__status--error {
  color: #ef4444;
}

/* ===========================
   Footer
   =========================== */
.footer {
  background: #0f172a;
  color: rgba(255,255,255,0.7);
  padding: 56px 0 0;
}

.footer__inner {
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

@media (min-width: 768px) {
  .footer__inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: start;
  }
}

.footer__logo {
  font-family: var(--font-en);
  font-size: 1.3rem;
  font-weight: 700;
  text-decoration: none;
}

.footer__desc {
  font-size: 0.85rem;
  margin-top: 8px;
  color: rgba(255,255,255,0.5);
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.footer__nav a {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  transition: color var(--transition);
}

.footer__nav a:hover {
  color: var(--white);
}

.footer__bottom {
  padding: 24px 0;
  text-align: center;
}

.footer__bottom p {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.4);
}

/* ===========================
   Animations
   =========================== */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===========================
   Utility
   =========================== */
@media (max-width: 767px) {
  .company__table th {
    width: 110px;
    font-size: 0.82rem;
    padding: 12px 14px;
  }
  .company__table td {
    font-size: 0.82rem;
    padding: 12px 14px;
  }
}
