/* ============================================================
   印花税计算器 · 印章红主题（仅作用于 .stamp-tax 作用域）
   设计思路：以「印泥红」为主色，配 CSS 绘制的红色印章徽标，
   结果区「实际应缴」做成醒目印章卡片。不动任何共享样式，
   仅通过覆盖 --c-primary 系列变量实现整体红色化。
   ============================================================ */

.stamp-tax {
    /* 印泥红主色，覆盖共享变量，使全工具统一走红调 */
    --st-red: #c1272d;
    --c-primary: #c1272d;
    --c-primary-soft: rgba(193, 39, 45, .10);
}
:root[data-theme="dark"] .stamp-tax {
    --st-red: #e0595f;
    --c-primary: #e0595f;
    --c-primary-soft: rgba(224, 89, 95, .14);
}

/* ---------- 顶部印章徽标 + 标题 ---------- */
.stamp-tax .st-head {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}
.stamp-tax .st-seal {
    flex: 0 0 auto;
    width: 56px;
    height: 56px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    place-items: center;
    border: 2.5px solid var(--st-red);
    border-radius: 11px;
    color: var(--st-red);
    background: rgba(193, 39, 45, .04);
    box-shadow: inset 0 0 0 2px rgba(193, 39, 45, .16);
    transform: rotate(-7deg);
    font-weight: 800;
    font-size: 17px;
    line-height: 1;
    user-select: none;
}
.stamp-tax .st-seal i { font-style: normal; }
.stamp-tax .dt-title {
    color: var(--st-red);
    letter-spacing: -0.01em;
}

/* ---------- 工具卡片：顶部红色标识条 ---------- */
.stamp-tax .dt-card-tool {
    border-top: 3px solid var(--st-red);
    overflow: hidden;
}

/* ---------- 结果卡片：强化印章感 ---------- */
.stamp-tax #stCards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.stamp-tax #stCards .tc-card {
    border-color: rgba(193, 39, 45, .20);
}
.stamp-tax #stCards .tc-card.is-primary {
    border-color: rgba(193, 39, 45, .42);
    background: rgba(193, 39, 45, .07);
}
.stamp-tax #stCards .tc-card.is-primary .v { color: var(--st-red); }

/* 「实际应缴」做成醒目印章卡（始终为最后一张） */
.stamp-tax #stCards .tc-card:last-child {
    grid-column: 1 / -1;
    border: 2px solid var(--st-red);
    background: var(--c-primary-soft);
    padding: 16px 18px;
    position: relative;
}
.stamp-tax #stCards .tc-card:last-child .k { font-size: 13px; }
.stamp-tax #stCards .tc-card:last-child .v {
    font-size: 30px;
    letter-spacing: -0.02em;
}
.stamp-tax #stCards .tc-card:last-child .n { font-size: 12.5px; }
/* 卡片右上角小印章 */
.stamp-tax #stCards .tc-card:last-child::after {
    content: "印花";
    position: absolute;
    right: -8px;
    top: -8px;
    transform: rotate(13deg);
    font-size: 12px;
    font-weight: 800;
    color: rgba(193, 39, 45, .55);
    border: 1.5px solid rgba(193, 39, 45, .45);
    border-radius: 6px;
    padding: 1px 6px;
    background: rgba(255, 255, 255, .6);
}
:root[data-theme="dark"] .stamp-tax #stCards .tc-card:last-child::after {
    background: rgba(40, 20, 22, .55);
}

/* ---------- 计算面板：右下角淡印章水印 ---------- */
.stamp-tax .st-panel[data-panel="calc"] {
    position: relative;
}
.stamp-tax .st-panel[data-panel="calc"]::before {
    content: "印";
    position: absolute;
    right: 10px;
    bottom: 6px;
    font-size: 96px;
    font-weight: 800;
    line-height: 1;
    color: rgba(193, 39, 45, .045);
    pointer-events: none;
    z-index: 0;
}

/* ---------- 标签激活态（已因 --c-primary 变红，这里加一点细节） ---------- */
.stamp-tax .dt-inner-tab.active {
    font-weight: 800;
    box-shadow: 0 2px 0 0 var(--st-red) inset;
}

/* ---------- 申报要点 / 税率表的标题点红 ---------- */
.stamp-tax .tc-sub h3::before {
    content: "";
    display: inline-block;
    width: 4px;
    height: 14px;
    margin-right: 8px;
    vertical-align: -2px;
    border-radius: 2px;
    background: var(--st-red);
}

/* ---------- 响应式 ---------- */
@media (max-width: 640px) {
    .stamp-tax #stCards { grid-template-columns: 1fr; }
    .stamp-tax .st-seal { width: 46px; height: 46px; font-size: 14px; }
    .stamp-tax #stCards .tc-card:last-child .v { font-size: 26px; }
}
