@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Inter:wght@400;500;600&display=swap');

:root{
  --color-bg: #ffffff;
  --color-bg-soft: #0a1f3d;
  --color-highlight-soft: #eef3fa;
  --color-primary: #14335e;
  --color-primary-dark: #0b2039;
  --color-accent: #e8a33d;
  --color-text: #10201d;
  --color-text-muted: #5b6b67;
  --color-border: #dbe7e3;
  --color-success: #3f8f5f;
  --color-danger: #c1443b;
  --color-info: #2e7dd1;
  --radius-card: 18px;
  --radius-control: 12px;
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
}

*{ box-sizing: border-box; }

body{
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg-soft);
  -webkit-font-smoothing: antialiased;
}

.screen{
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
}

.card{
  width: 100%;
  max-width: 420px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: 32px 28px;
}

.brand{
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--color-primary-dark);
  letter-spacing: -0.01em;
  margin: 0 0 4px;
}

.brand-sub{
  color: var(--color-text-muted);
  font-size: 0.95rem;
  margin: 0 0 28px;
  line-height: 1.5;
}

h1.title{
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.3;
  margin: 0 0 8px;
  color: var(--color-text);
}

p.subtitle{
  color: var(--color-text-muted);
  margin: 0 0 24px;
  line-height: 1.5;
}

label{
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin: 16px 0 6px;
  color: var(--color-text);
}

label:first-of-type{ margin-top: 0; }

input, select, textarea{
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-control);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-text);
  background: var(--color-bg);
}

input:focus, select:focus, textarea:focus{
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(11,79,74,0.12);
}

textarea{ resize: vertical; min-height: 88px; }

.btn{
  display: block;
  width: 100%;
  padding: 14px 18px;
  border-radius: var(--radius-control);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.98rem;
  text-align: center;
  border: none;
  cursor: pointer;
  text-decoration: none;
  margin-top: 22px;
}

.btn-primary{ background: var(--color-primary); color: #fff; }
.btn-primary:hover{ background: var(--color-primary-dark); }

.btn-outline{
  background: transparent;
  color: var(--color-primary-dark);
  border: 1px solid var(--color-border);
  margin-top: 12px;
}

.btn-google{
  background: #fff;
  color: var(--color-text);
  border: 1px solid var(--color-border);
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.divider{
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--color-text-muted);
  font-size: 0.8rem;
  margin: 22px 0 0;
}
.divider::before, .divider::after{
  content: '';
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

.footnote{
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: 20px;
}
.footnote a{ color: var(--color-primary); font-weight: 600; text-decoration: none; }

.role-options{
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 8px;
}

.role-card{
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background: var(--color-bg);
  cursor: pointer;
  text-align: left;
  width: 100%;
  font-family: var(--font-body);
}

.role-card:hover{ border-color: var(--color-primary); }

.role-icon{
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--color-highlight-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

.role-title{ font-weight: 600; margin: 0 0 2px; color: var(--color-text); }
.role-desc{ font-size: 0.85rem; color: var(--color-text-muted); margin: 0; }

.section-label{
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 28px 0 4px;
}
.section-label:first-of-type{ margin-top: 4px; }

.hint{
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-top: 4px;
}

.error-text{
  font-size: 0.85rem;
  color: var(--color-danger);
  margin-top: 10px;
  display: none;
}

.checkbox-row{
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
}
.checkbox-row input{ width: auto; margin-top: 3px; }
.checkbox-row label{ margin: 0; font-weight: 400; font-size: 0.85rem; color: var(--color-text-muted); }

#map-picker{
  width: 100%;
  height: 220px;
  border-radius: var(--radius-control);
  border: 1px solid var(--color-border);
  margin-top: 6px;
}

.topnav{
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 480px;
  margin: 0 auto;
  padding: 16px 20px 0;
}
.topnav a{
  font-size: 0.88rem;
  font-weight: 600;
  color: #ffffff;
  text-decoration: none;
}
.topnav .logout-link{
  color: rgba(255, 255, 255, 0.75);
  font-weight: 500;
}

/* --- グローバルナビゲーション(プルダウンメニュー) --- */
.app-nav{
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 480px;
  margin: 0 auto;
  padding: 14px 20px 0;
  position: relative;
}
.app-nav .brand-mini{
  font-family: var(--font-display);
  font-weight: 700;
  color: #ffffff;
  text-decoration: none;
  font-size: 1.05rem;
}
.app-nav .menu-toggle{
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  width: 40px;
  height: 40px;
  font-size: 1.1rem;
  cursor: pointer;
  color: var(--color-text);
}
.app-nav .dropdown{
  position: absolute;
  top: 54px;
  right: 20px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: 0 8px 24px rgba(16, 32, 29, 0.12);
  min-width: 200px;
  display: none;
  z-index: 20;
  overflow: hidden;
}
.app-nav .dropdown.open{ display: block; }
.app-nav .dropdown a{
  display: block;
  padding: 13px 16px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  text-decoration: none;
  border-bottom: 1px solid var(--color-border);
}
.app-nav .dropdown a:last-child{ border-bottom: none; }
.app-nav .dropdown a.danger{ color: var(--color-danger); }
.app-nav .dropdown a.active-link{ color: var(--color-primary); font-weight: 700; }

/* --- 注文/仕事ステータスの色分け --- */
.status-neutral{ color: var(--color-text-muted); }
.status-progress{ color: var(--color-info); }
.status-warning{ color: var(--color-accent); }
.status-success{ color: var(--color-success); }
.status-danger{ color: var(--color-danger); }

/* --- 濃紺の背景に直接乗るテキスト(カードの外側)は白系にする --- */
.orders-wrap > h1.title{ color: #ffffff; }
.orders-wrap > p.subtitle,
.orders-wrap > p.hint{ color: rgba(255, 255, 255, 0.8); }
.empty-state{ color: rgba(255, 255, 255, 0.7); }
