@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@300;400;500;700;900&family=DM+Mono:wght@400;500&display=swap");
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  max-width: 100%;
  overflow-x: clip;
}

[hidden] {
  display: none !important;
}

:where(button, a[href], input, select, textarea, [tabindex]):focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.55);
  outline-offset: 2px;
}

input[type=number] {
  appearance: textfield;
  -moz-appearance: textfield;
}

input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type=checkbox], input[type=radio] {
  accent-color: var(--primary);
}

button {
  font-family: inherit;
}

:root {
  --primary: #2563EB;
  --primary-text: #FFFFFF;
  --accent: #F59E0B;
  --accent-2: #14B8A6;
  --accent-2-soft: #CCFBF1;
  --primary-soft: #EAF2FF;
  --primary-tint: #F5F8FF;
  --warning-soft: #FFFBEB;
  --success-soft: #ECFDF5;
  --bg: #EEF4F8;
  --card-bg: #FFFFFF;
  --text: #1E293B;
  --text-muted: #64748B;
  --border: #D7E1EE;
  --danger: #DC2626;
  --step-active: #2563EB;
  --step-done: #10B981;
  --radius: 12px;
  --shadow: 0 12px 30px rgba(15,23,42,0.065);
  --shadow-lg: 0 22px 54px rgba(15,23,42,0.14);
  --fs-xxs: 10px;
  --fs-xs: 11px;
  --fs-sm: 12px;
  --fs-md: 13px;
  --fs-base: 15px;
  --fs-ui: 14px;
  --fs-title: 18px;
  --fs-header: 20px;
  --fs-plan-price: 22px;
  --fs-price-total: 40px;
  --fs-result-total: 20px;
}

body {
  font-family: "Noto Sans JP", sans-serif;
  background: radial-gradient(circle at 10% 0%, rgba(37, 99, 235, 0.13), transparent 28%), linear-gradient(135deg, #F7FBFF 0%, var(--bg) 46%, #F0FDF9 100%);
  color: var(--text);
  min-height: 100vh;
  font-size: var(--fs-base);
  overflow-x: clip;
  padding-top: 68px;
}

.header {
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(215, 225, 238, 0.86);
  padding: 0 28px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 220;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 18px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.055);
  -webkit-backdrop-filter: blur(14px) saturate(135%);
  backdrop-filter: blur(14px) saturate(135%);
}

.header-title {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 auto;
  min-width: 0;
  font-size: var(--fs-header);
  font-weight: 900;
  color: #0F172A;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
}

.header-title-text {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-title::before {
  content: "";
  width: 12px;
  flex: 0 0 12px;
  height: 28px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--primary), var(--accent-2));
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.22);
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex: 0 0 auto;
  min-width: 0;
}

.header-action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 999px;
  background: #FFFFFF;
  color: var(--primary);
  font-size: var(--fs-md);
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.header-action-link:hover {
  background: var(--primary-tint);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
  transform: translateY(-1px);
}

.header-admin-link {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-text);
}

.header-admin-link:hover {
  background: #1D4ED8;
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.22);
}

.header-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  font-size: var(--fs-md);
  background: #111827;
  color: #FFFFFF;
  padding: 0 15px;
  border-radius: 999px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 10px 22px rgba(17, 24, 39, 0.16);
}

.container {
  max-width: 1760px;
  margin: 0 auto;
  padding: 34px clamp(20px, 3vw, 48px) 80px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: clamp(28px, 2.5vw, 36px);
  align-items: start;
  min-width: 0;
}

main, .sidebar {
  min-width: 0;
}

@media (max-width: 1120px) {
  .container {
    grid-template-columns: 1fr;
  }
  .sidebar {
    order: -1;
    top: 76px;
  }
}
@media (max-width: 860px) {
  :root {
    --fs-xs: 10px;
    --fs-sm: 11px;
    --fs-md: 12px;
    --fs-base: 14px;
    --fs-ui: 13px;
    --fs-title: 17px;
    --fs-header: 17px;
    --fs-plan-price: 20px;
    --fs-price-total: 32px;
    --fs-result-total: 18px;
  }
  .container {
    grid-template-columns: 1fr;
  }
  .sidebar {
    order: -1;
  }
}
@media (max-width: 480px) {
  :root {
    --fs-xs: 10px;
    --fs-sm: 11px;
    --fs-md: 12px;
    --fs-base: 14px;
    --fs-ui: 13px;
    --fs-title: 16px;
    --fs-header: 16px;
    --fs-plan-price: 19px;
    --fs-price-total: 28px;
    --fs-result-total: 17px;
  }
  body {
    padding-top: 64px;
  }
}
