/**
 * 薪の必要量 計算ツール - 専用スタイル
 */

/* ===== 入力フィールド ===== */
.fw-field {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 11px 0;
	border-bottom: 1px solid var(--color-border);
}

.fw-field:last-child {
	border-bottom: none;
}

.fw-field-label {
	font-size: 14px;
	font-weight: 500;
	color: var(--color-text);
}

.fw-select {
	flex: 1;
	max-width: 240px;
	padding: 10px 12px;
	font-size: 14px;
	font-family: inherit;
	color: var(--color-text);
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
}

/* ===== ステッパー（時間） ===== */
.fw-stepper {
	display: flex;
	align-items: center;
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	overflow: hidden;
	background: var(--color-white);
	flex-shrink: 0;
}

.fw-step {
	width: 38px;
	height: 38px;
	border: none;
	background: var(--color-bg);
	color: var(--color-primary);
	font-size: 20px;
	font-weight: 700;
	line-height: 1;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.fw-step:hover {
	background: var(--color-accent);
	color: var(--color-white);
}

.fw-step:active {
	background: var(--color-accent-hover);
}

.fw-step-input {
	width: 44px;
	height: 38px;
	border: none;
	border-left: 1px solid var(--color-border);
	text-align: center;
	font-size: 16px;
	font-weight: 700;
	color: var(--color-text);
	font-family: inherit;
	background: var(--color-white);
	-moz-appearance: textfield;
	appearance: textfield;
}

.fw-step-input::-webkit-outer-spin-button,
.fw-step-input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.fw-step-input:focus {
	outline: none;
	background: rgba(224, 120, 80, 0.06);
}

.fw-step-unit {
	height: 38px;
	display: flex;
	align-items: center;
	padding: 0 10px;
	font-size: 13px;
	color: var(--color-text-secondary);
	background: var(--color-white);
	border-right: 1px solid var(--color-border);
}

/* ===== 結果 ===== */
.fw-result {
	margin-top: 20px;
}

.fw-result-summary {
	font-family: var(--font-display);
	font-size: 15px;
	font-weight: 700;
	color: var(--color-white);
	background: var(--color-accent);
	padding: 10px 14px;
	border-radius: var(--radius);
	margin-bottom: 14px;
	line-height: 1.5;
}

.fw-total-box {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
	padding: 18px 16px;
	background: var(--color-bg);
	border-radius: var(--radius);
	margin-bottom: 14px;
}

.fw-total-label {
	font-size: 13px;
	color: var(--color-text-secondary);
}

.fw-total-value {
	font-family: var(--font-display);
	font-size: 34px;
	font-weight: 700;
	color: var(--color-accent);
	line-height: 1.1;
}

.fw-total-value small {
	font-size: 18px;
	margin-left: 2px;
}

.fw-result-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.fw-result-item {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 4px;
	border-bottom: 1px solid var(--color-border);
}

.fw-result-item:last-child {
	border-bottom: none;
}

.fw-result-name {
	font-size: 14px;
	color: var(--color-text);
}

.fw-result-amount {
	font-size: 14px;
	font-weight: 700;
	color: var(--color-primary-dark);
	text-align: right;
	flex-shrink: 0;
}

/* ===== 早見表 ===== */
.fw-table-wrap {
	overflow-x: auto;
	margin: 6px 0 12px;
}

.fw-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
	min-width: 460px;
}

.fw-table th,
.fw-table td {
	padding: 10px 12px;
	text-align: center;
	border: 1px solid var(--color-border);
}

.fw-table thead th {
	background: var(--color-primary);
	color: var(--color-white);
	font-weight: 700;
	font-size: 13px;
}

.fw-table tbody tr:nth-child(even) {
	background: var(--color-bg);
}

.fw-table tbody td:first-child {
	font-weight: 700;
	color: var(--color-primary-dark);
}

/* ===== レスポンシブ ===== */
@media (max-width: 480px) {
	.fw-field {
		flex-direction: column;
		align-items: stretch;
		gap: 8px;
	}

	.fw-select {
		max-width: none;
	}

	.fw-stepper {
		align-self: flex-start;
	}
}
