* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: linear-gradient(135deg, #e0f2fe 0%, #c7d2fe 100%);
  min-height: 100vh;
  padding: 0;
}

/* ヘッダー */
.site-header {
  background-color: #1f2937;
  color: white;
  padding: 0.5rem 1rem;
  margin-bottom: 2rem;
}

.header-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
  font-size: 1.125rem;
}

.header-link:hover {
  opacity: 0.9;
}

.header-logo {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  object-fit: cover;
}

.container {
  max-width: 56rem;
  margin: 0 auto;
  padding: 0 2rem 2rem;
}

.header {
  text-align: center;
  margin-bottom: 2rem;
}

h1 {
  font-size: 2.25rem;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.subtitle {
  color: #6b7280;
}

.card {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  margin-bottom: 1.5rem;
}

.input-group {
  margin-bottom: 1.5rem;
}

.label {
  display: flex;
  align-items: center;
  font-size: 1.125rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.75rem;
}

.icon {
  width: 20px;
  height: 20px;
  margin-right: 0.5rem;
}

input[type="range"] {
  width: 100%;
  height: 12px;
  border-radius: 0.5rem;
  appearance: none;
  cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: white;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input[type="range"]::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: white;
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.range-participants { background: #bfdbfe; }
.range-hours { background: #bbf7d0; }
.range-rate { background: #ddd6fe; }

.value-display {
  text-align: right;
  font-size: 1.5rem;
  font-weight: 700;
  margin-top: 0.5rem;
}

.value-participants { color: #2563eb; }
.value-hours { color: #16a34a; }
.value-rate { color: #9333ea; }

.frequency-section {
  border-top: 1px solid #e5e7eb;
  padding-top: 1.5rem;
}

.radio-group {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

.radio-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: 1.125rem;
}

input[type="radio"] {
  width: 1.25rem;
  height: 1.25rem;
  margin-right: 0.5rem;
  cursor: pointer;
}

.day-selector {
  margin-top: 1rem;
}

.day-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.day-button {
  padding: 0.75rem;
  border: none;
  border-radius: 0.5rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  background: #f3f4f6;
  color: #4b5563;
}

.day-button.active {
  background: #3b82f6;
  color: white;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transform: scale(1.05);
}

.day-button:hover:not(.active) {
  background: #e5e7eb;
}

.day-info {
  text-align: center;
  color: #6b7280;
  font-size: 0.875rem;
  margin-top: 0.75rem;
}

.day-count {
  font-weight: 700;
  color: #2563eb;
}

.cost-card {
  background: linear-gradient(135deg, #ef4444 0%, #f97316 100%);
  border-radius: 1rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  padding: 2rem;
  color: white;
  text-align: center;
}

.cost-header {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.5rem;
}

.cost-title {
  font-size: 1.5rem;
  font-weight: 700;
}

.cost-amount {
  font-size: 3.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.cost-details {
  font-size: 1.25rem;
  opacity: 0.9;
}

.share-button {
  width: 100%;
  padding: 0.75rem 1.5rem;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: white;
  border: none;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  margin-top: 1.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.share-button:hover {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.15);
}

.share-button:active {
  transform: translateY(0);
}

.share-message {
  margin-top: 0.75rem;
  padding: 0.5rem 1rem;
  background: #dbeafe;
  border: 2px solid #3b82f6;
  border-radius: 0.5rem;
  text-align: center;
  font-weight: 600;
  color: #1e40af;
  animation: fadeInOut 2s ease-in-out;
}

@keyframes fadeInOut {
  0%, 100% { opacity: 0; }
  10%, 90% { opacity: 1; }
}

.comparison-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  text-align: center;
  margin-bottom: 1.5rem;
}

.comparison-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
  background: linear-gradient(135deg, #eff6ff 0%, #e0e7ff 100%);
  border: 2px solid #bfdbfe;
  border-radius: 0.75rem;
  margin-bottom: 1rem;
}

.item-info {
  display: flex;
  align-items: center;
}

.item-emoji {
  font-size: 2.5rem;
  margin-right: 1rem;
}

.item-name {
  font-weight: 700;
  font-size: 1.125rem;
  color: #1f2937;
}

.item-quantity {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ef4444;
  margin-top: 0.25rem;
}

.item-price {
  font-size: 1.25rem;
  font-weight: 600;
  color: #2563eb;
}

.footer {
  margin-top: 1.5rem;
  text-align: center;
  color: #6b7280;
  font-size: 0.875rem;
}

.hidden {
  display: none;
}

.calculate-button {
  width: 100%;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: white;
  border: none;
  border-radius: 0.75rem;
  font-size: 1.25rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  margin-top: 1rem;
}

.calculate-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15);
}

.calculate-button:active {
  transform: translateY(0);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
