/* リセットCSS */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans JP', sans-serif;
    background: linear-gradient(135deg, #e3f2fd 0%, #c5cae9 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
}

.main-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    padding: 32px;
}

/* ヘッダー */
.header {
    text-align: center;
    margin-bottom: 32px;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.calculator-icon {
    color: #2563eb;
    margin-right: 12px;
}

.header h1 {
    font-size: 32px;
    font-weight: 700;
    color: #1f2937;
}

.subtitle {
    color: #6b7280;
    font-size: 16px;
}

/* サービス選択 */
.service-selector {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 32px;
}

.service-btn {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #f3f4f6;
    color: #374151;
}

.service-btn:hover {
    background: #e5e7eb;
}

.service-btn.active {
    background: #2563eb;
    color: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.service-btn svg {
    margin-right: 8px;
}

/* メインコンテンツ */
.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

/* フォームセクション */
.form-section h3 {
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 8px;
    margin-bottom: 24px;
}

.input-group {
    margin-bottom: 24px;
}

.input-group label {
    display: flex;
    align-items: center;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
}

.input-group label svg {
    margin-right: 4px;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* サイズ入力 */
.size-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
    margin-bottom: 24px;
}

.mail-size-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 24px;
}

.zone-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* 結果セクション */
.results-section h3 {
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 8px;
    margin-bottom: 24px;
}

#results-container {
    min-height: 200px;
}

.empty-state {
    text-align: center;
    padding: 32px;
    color: #6b7280;
}

.empty-state svg {
    opacity: 0.5;
    margin-bottom: 16px;
}

.result-card {
    background: linear-gradient(135deg, #eff6ff 0%, #e0e7ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 16px;
}

.result-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.result-company {
    display: flex;
    align-items: center;
}

.result-company svg {
    color: #2563eb;
    margin-right: 8px;
}

.company-name {
    font-weight: 600;
    color: #1f2937;
}

.best-price {
    background: #dcfce7;
    color: #166534;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 9999px;
    margin-left: 8px;
}

.result-details {
    space-y: 4px;
}

.result-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.service-name {
    color: #6b7280;
}

.price {
    font-weight: 700;
    font-size: 18px;
    color: #2563eb;
}

.result-info {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 4px;
}

.discount-info {
    font-size: 14px;
    color: #6b7280;
}

.original-price {
    text-decoration: line-through;
}

.discount-note {
    color: #059669;
    margin-left: 8px;
}

.discount-note svg {
    width: 12px;
    height: 12px;
    margin-right: 4px;
}

.future-price {
    font-size: 14px;
    color: #ea580c;
}

.note {
    font-size: 14px;
    color: #6b7280;
}

/* 注意事項 */
.notice {
    margin-top: 32px;
    padding: 16px;
    background: #fefce8;
    border: 1px solid #fde047;
    border-radius: 8px;
}

.notice h4 {
    font-weight: 600;
    color: #a16207;
    margin-bottom: 8px;
}

.notice ul {
    list-style: none;
}

.notice li {
    font-size: 14px;
    color: #a16207;
    margin-bottom: 4px;
}

/* 非表示要素 */
.hidden {
    display: none !important;
}

/* アニメーション */
.fade-in {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* レスポンシブ */
@media (max-width: 640px) {
    .container {
        padding: 16px;
    }

    .main-card {
        padding: 24px;
    }

    .header h1 {
        font-size: 24px;
    }

    .service-selector {
        flex-direction: column;
        align-items: center;
    }

    .service-btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }

    .size-inputs {
        grid-template-columns: 1fr;
    }

    .mail-size-inputs {
        grid-template-columns: 1fr;
    }

    .zone-inputs {
        grid-template-columns: 1fr;
    }
}