/**
 * Gift Tax Calculator Styles
 * 증여세 계산기 전용 스타일
 *
 * @package Zipper
 */

/* ===== 2컬럼 레이아웃 (데스크탑) ===== */
.gtc-main-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 20px;
    align-items: start;
}

.gtc-input-col {
    position: sticky;
    top: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.gtc-result-col {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ===== 공통 섹션 ===== */
.gtc-section {
    background: #fff;
    border: 1px solid #e8e4dc;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(45, 42, 38, 0.06);
}

.gtc-section + .gtc-section {
    margin-top: 14px;
}

.gtc-section-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d2a26;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-section-title i {
    color: #d4af37;
    font-size: 14px;
}

/* ===== 탭 (계산/역산) ===== */
.gtc-tab-group {
    display: flex;
    gap: 4px;
    background: #f5f3f0;
    border-radius: 8px;
    padding: 3px;
    margin-bottom: 14px;
}

.gtc-tab {
    flex: 1;
    padding: 8px 6px;
    font-size: 12px;
    font-weight: 500;
    text-align: center;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: #9e9a96;
    cursor: pointer;
    transition: all 0.2s;
}

.gtc-tab:hover {
    color: #5f5a56;
}

.gtc-tab.active {
    background: #fff;
    color: #d4af37;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.gtc-tab-content {
    display: none;
}

.gtc-tab-content.active {
    display: block;
}

/* ===== 입력 그룹 ===== */
.gtc-input-group {
    margin-bottom: 12px;
    max-width: 100%;
    box-sizing: border-box;
}

.gtc-input-group:last-child {
    margin-bottom: 0;
}

.gtc-input-label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #5f5a56;
    margin-bottom: 6px;
}

.gtc-input-label .gtc-label-hint {
    font-weight: 400;
    color: #9e9a96;
    margin-left: 4px;
}

.gtc-amount-input {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 10px 12px;
    font-size: 15px;
    font-weight: 600;
    text-align: right;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    background: #faf9f7;
    color: #2d2a26;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.gtc-amount-input:focus {
    outline: none;
    border-color: #d4af37;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.gtc-amount-input::placeholder {
    font-weight: 400;
    color: #c4c0bc;
}

.gtc-select {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 10px 12px;
    font-size: 13px;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    background: #faf9f7;
    color: #2d2a26;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%235f5a56' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

.gtc-select:focus {
    outline: none;
    border-color: #d4af37;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.gtc-korean-amount {
    font-size: 11px;
    color: #d4af37;
    margin-top: 4px;
    text-align: right;
    min-height: 16px;
}

.gtc-hint {
    font-size: 11px;
    color: #9e9a96;
    margin-top: 4px;
}

/* ===== 라디오 버튼 ===== */
.gtc-radio-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.gtc-radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    font-size: 13px;
    color: #5f5a56;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    background: #faf9f7;
    cursor: pointer;
    transition: all 0.2s;
}

.gtc-radio-label:hover {
    border-color: #d4af37;
}

.gtc-radio-label input[type="radio"] {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #d4af37;
    flex-shrink: 0;
}

.gtc-radio-label.active {
    border-color: #d4af37;
    background: #fdfbf5;
    color: #2d2a26;
    font-weight: 500;
}

.gtc-radio-desc {
    font-size: 11px;
    color: #9e9a96;
    margin-left: auto;
}

/* ===== 체크박스 ===== */
.gtc-checkbox-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.gtc-checkbox-row:last-child {
    margin-bottom: 0;
}

.gtc-checkbox-label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    font-size: 12px;
    color: #5f5a56;
    border: 1px solid #e8e4dc;
    border-radius: 6px;
    background: #faf9f7;
    cursor: pointer;
    transition: all 0.2s;
}

.gtc-checkbox-label:hover {
    border-color: #d4af37;
}

.gtc-checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #d4af37;
    flex-shrink: 0;
}

.gtc-checkbox-label.active {
    border-color: #d4af37;
    background: #fdfbf5;
    color: #2d2a26;
    font-weight: 500;
}

.gtc-inline-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gtc-inline-group .gtc-input-label {
    margin-bottom: 0;
    white-space: nowrap;
}

.gtc-inline-group .gtc-unit {
    font-size: 12px;
    color: #5f5a56;
    white-space: nowrap;
}

/* ===== 고급 옵션 토글 ===== */
.gtc-advanced-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 0;
    font-size: 12px;
    font-weight: 500;
    color: #9e9a96;
    cursor: pointer;
    border: none;
    background: none;
    transition: color 0.2s;
    width: 100%;
}

.gtc-advanced-toggle:hover {
    color: #d4af37;
}

.gtc-advanced-toggle i {
    transition: transform 0.2s;
    font-size: 10px;
}

.gtc-advanced-toggle.open i {
    transform: rotate(90deg);
}

.gtc-advanced-content {
    display: none;
    padding-top: 4px;
}

.gtc-advanced-content.open {
    display: block;
}

/* ===== 버튼 ===== */
.gtc-btn-group {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}

.gtc-calculate-btn {
    flex: 1;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, #d4af37, #c9a030);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 6px rgba(212, 175, 55, 0.25);
}

.gtc-calculate-btn:hover {
    background: linear-gradient(135deg, #c9a030, #b8922a);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.3);
}

.gtc-reset-btn {
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 500;
    color: #5f5a56;
    background: #f5f3f0;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.gtc-reset-btn:hover {
    background: #eae7e3;
}

/* ===== 결과 - 대기 영역 ===== */
.gtc-waiting {
    text-align: center;
    padding: 40px 20px;
    color: #9e9a96;
}

.gtc-waiting i {
    font-size: 32px;
    margin-bottom: 12px;
    display: block;
    color: #d4af37;
    opacity: 0.4;
}

.gtc-waiting p {
    font-size: 13px;
    margin: 0;
}

/* ===== 결과 - 요약 카드 ===== */
.gtc-result-summary {
    background: #fdfbf5;
    border: 2px solid #d4af37;
    border-radius: 12px;
    padding: 24px;
}

.gtc-summary-title {
    font-size: 12px;
    color: #7a756d;
    margin-bottom: 8px;
}

.gtc-summary-main {
    font-size: 32px;
    font-weight: 700;
    color: #d4af37;
    margin-bottom: 4px;
    line-height: 1.2;
}

.gtc-summary-label {
    font-size: 13px;
    color: #5f5a56;
    margin-bottom: 16px;
}

.gtc-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-top: 1px solid #e8e4dc;
    font-size: 13px;
}

.gtc-summary-row-label {
    color: #7a756d;
}

.gtc-summary-row-value {
    font-weight: 600;
    color: #2d2a26;
}

/* ===== 결과 - 계산 흐름 ===== */
.gtc-flow-section {
    background: #fff;
    border: 1px solid #e8e4dc;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(45, 42, 38, 0.06);
}

.gtc-flow-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d2a26;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-flow-title i {
    color: #d4af37;
}

.gtc-flow-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.gtc-flow-step {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 13px;
}

.gtc-flow-step:nth-child(odd) {
    background: #faf9f7;
}

.gtc-flow-step-label {
    color: #5f5a56;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-flow-step-label .gtc-flow-op {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 11px;
    font-weight: 700;
}

.gtc-flow-op-minus {
    background: #fff0f0;
    color: #e74c3c;
}

.gtc-flow-op-equals {
    background: #f0f7ff;
    color: #3498db;
}

.gtc-flow-op-multiply {
    background: #fdf5e6;
    color: #d4af37;
}

.gtc-flow-op-plus {
    background: #f0fff0;
    color: #27ae60;
}

.gtc-flow-step-value {
    font-weight: 600;
    color: #2d2a26;
    text-align: right;
}

.gtc-flow-step.gtc-flow-highlight {
    background: #fdfbf5;
    border: 1px solid #e8dfc0;
}

.gtc-flow-step.gtc-flow-highlight .gtc-flow-step-value {
    color: #d4af37;
    font-size: 15px;
}

/* ===== 결과 - 세율 구간 시각화 ===== */
.gtc-bracket-section {
    background: #fff;
    border: 1px solid #e8e4dc;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(45, 42, 38, 0.06);
}

.gtc-bracket-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d2a26;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-bracket-title i {
    color: #d4af37;
}

.gtc-bracket-chart {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.gtc-bracket-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gtc-bracket-rate {
    width: 36px;
    font-size: 12px;
    font-weight: 600;
    color: #5f5a56;
    text-align: right;
    flex-shrink: 0;
}

.gtc-bracket-bar-wrap {
    flex: 1;
    height: 24px;
    background: #f5f3f0;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.gtc-bracket-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
    min-width: 0;
}

.gtc-bracket-range {
    font-size: 10px;
    color: #9e9a96;
    width: 90px;
    flex-shrink: 0;
    text-align: right;
}

.gtc-bracket-row.gtc-bracket-active .gtc-bracket-rate {
    color: #d4af37;
    font-weight: 700;
}

.gtc-bracket-row.gtc-bracket-active .gtc-bracket-fill {
    position: relative;
}

.gtc-bracket-row.gtc-bracket-active .gtc-bracket-fill::after {
    content: '\25C0 \B0B4 \AD6C\AC04';
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
}

.gtc-bracket-colors-10 { background: #c8e6c9; }
.gtc-bracket-colors-20 { background: #fff9c4; }
.gtc-bracket-colors-30 { background: #ffe0b2; }
.gtc-bracket-colors-40 { background: #ffab91; }
.gtc-bracket-colors-50 { background: #ef9a9a; }

.gtc-effective-rate {
    margin-top: 12px;
    padding: 10px 12px;
    background: #fdfbf5;
    border: 1px solid #e8dfc0;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
}

.gtc-effective-rate-label {
    color: #5f5a56;
}

.gtc-effective-rate-value {
    font-weight: 700;
    color: #d4af37;
    font-size: 16px;
}

/* ===== 결과 - 공제 한도 안내 ===== */
.gtc-exemption-info {
    background: #fff;
    border: 1px solid #e8e4dc;
    border-radius: 12px;
    padding: 16px;
}

.gtc-exemption-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d2a26;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-exemption-title i {
    color: #d4af37;
}

.gtc-exemption-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: #fdfbf5;
    border: 1px solid #e8dfc0;
    border-radius: 8px;
    margin-bottom: 8px;
}

.gtc-exemption-card:last-child {
    margin-bottom: 0;
}

.gtc-exemption-card-label {
    font-size: 13px;
    color: #5f5a56;
}

.gtc-exemption-card-value {
    font-size: 15px;
    font-weight: 700;
    color: #d4af37;
}

.gtc-exemption-note {
    font-size: 11px;
    color: #9e9a96;
    margin-top: 8px;
    line-height: 1.5;
}

/* ===== 결과 - 신고 기한 ===== */
.gtc-deadline-section {
    background: #fff;
    border: 1px solid #e8e4dc;
    border-radius: 12px;
    padding: 16px;
}

.gtc-deadline-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d2a26;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-deadline-title i {
    color: #d4af37;
}

.gtc-deadline-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: #fdfbf5;
    border: 1px solid #e8dfc0;
    border-radius: 8px;
}

.gtc-deadline-card-label {
    font-size: 13px;
    color: #5f5a56;
}

.gtc-deadline-card-value {
    font-size: 15px;
    font-weight: 700;
    color: #d4af37;
}

.gtc-deadline-note {
    font-size: 11px;
    color: #9e9a96;
    margin-top: 8px;
    line-height: 1.5;
}

/* ===== 결과 - 팁 ===== */
.gtc-tips-section {
    background: #fff;
    border: 1px solid #e8e4dc;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(45, 42, 38, 0.06);
}

.gtc-tips-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d2a26;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gtc-tips-title i {
    color: #d4af37;
}

.gtc-tips-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.gtc-tip-card {
    display: flex;
    gap: 10px;
    padding: 10px 12px;
    background: #faf9f7;
    border-radius: 8px;
    font-size: 12px;
    line-height: 1.5;
    color: #5f5a56;
}

.gtc-tip-icon {
    font-size: 16px;
    color: #d4af37;
    flex-shrink: 0;
    margin-top: 1px;
}

.gtc-tip-text strong {
    color: #2d2a26;
}

.gtc-tip-saving {
    display: inline-block;
    padding: 1px 6px;
    background: #fdfbf5;
    border: 1px solid #e8dfc0;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    color: #d4af37;
    margin-left: 4px;
}

/* ===== 면책 조항 ===== */
.gtc-disclaimer {
    display: flex;
    gap: 8px;
    padding: 10px 12px;
    background: #faf9f7;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    font-size: 11px;
    color: #9e9a96;
    line-height: 1.5;
}

.gtc-disclaimer i {
    color: #d4af37;
    flex-shrink: 0;
    margin-top: 2px;
}

/* ===== 유틸리티 ===== */
.gtc-hidden {
    display: none !important;
}

/* ===== 날짜 입력 ===== */
.gtc-date-input {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 10px 12px;
    font-size: 13px;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    background: #faf9f7;
    color: #2d2a26;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.gtc-date-input:focus {
    outline: none;
    border-color: #d4af37;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

/* ===== 할증 선택 ===== */
.gtc-surcharge-group {
    margin-top: 8px;
    padding: 8px 10px;
    background: #faf9f7;
    border-radius: 6px;
}

/* ===== 반응형 ===== */
@media (max-width: 900px) {
    .gtc-main-layout {
        grid-template-columns: 1fr;
    }

    .gtc-input-col {
        position: static;
        width: 100%;
    }

    .gtc-result-col {
        width: 100%;
    }

    .tool-layout-input {
        max-width: 100%;
        overflow: hidden;
    }

    .gtc-input-group input:not([type="radio"]):not([type="checkbox"]):not([type="date"]),
    .gtc-input-group select {
        width: 100% !important;
        max-width: 100% !important;
    }

    .gtc-bracket-range {
        width: 70px;
        font-size: 9px;
    }

    .gtc-summary-main {
        font-size: 26px;
    }
}

@media (max-width: 480px) {
    .tool-section,
    .tool-layout-split,
    .tool-layout-input,
    .tool-layout-result {
        max-width: 100%;
        overflow-x: hidden;
    }

    .gtc-section {
        padding: 12px;
    }

    .gtc-result-summary {
        padding: 16px;
    }

    .gtc-summary-main {
        font-size: 22px;
    }

    .gtc-bracket-row {
        gap: 4px;
    }

    .gtc-bracket-range {
        display: none;
    }

    .gtc-checkbox-row {
        flex-direction: column;
    }

    .gtc-inline-group {
        flex-wrap: wrap;
    }
}
