/* PPM to Percentage Calculator — Plugin Styles */

.pptc-wrap {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    max-width: 900px;
    margin: 0 auto;
    color: #0f172a;
    box-sizing: border-box;
}
.pptc-wrap *, .pptc-wrap *::before, .pptc-wrap *::after { box-sizing: border-box; }

/* Header */
.pptc__header { text-align: center; margin-bottom: 24px; }
.pptc__header h2 {
    font-size: 26px !important; font-weight: 800 !important; color: #0f172a !important;
    margin: 0 0 8px 0 !important; letter-spacing: -0.02em; line-height: 1.2;
}
.pptc__header p { color: #64748b; font-size: 14px; margin: 0; line-height: 1.6; }

/* Body card */
.pptc__body {
    background: #fff; border: 1.5px solid #e2e8f0; border-radius: 16px;
    overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,0.06); margin-bottom: 20px;
}

/* Tabs */
.pptc__tabs { display: flex; border-bottom: 1.5px solid #e2e8f0; background: #f8fafc; }
.pptc__tab {
    flex: 1; padding: 13px 16px; font-size: 13px; font-weight: 700; cursor: pointer;
    border: none; border-bottom: 2.5px solid transparent; background: transparent;
    color: #64748b; transition: all 0.15s; font-family: inherit;
}
.pptc__tab--active { background: #fff; color: #0ea5e9; border-bottom-color: #0ea5e9; }

/* Inner sections */
.pptc__presets-section, .pptc__input-section { padding: 18px 24px 0; }
.pptc__input-section { padding-bottom: 18px; }

/* Presets */
.pptc__presets-label {
    display: block; font-size: 11px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 1px; color: #94a3b8; margin-bottom: 8px;
}
.pptc__presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 4px; }
.pptc__preset {
    padding: 5px 12px; border-radius: 6px; border: 1.5px solid #e2e8f0;
    background: #f8fafc; color: #475569; font-size: 12px; font-weight: 600;
    cursor: pointer; font-family: inherit; transition: all 0.15s;
}
.pptc__preset:hover { border-color: #93c5fd; background: #eff6ff; color: #1d4ed8; }
.pptc__preset.pptc--active { border-color: #0ea5e9; background: #e0f2fe; color: #0284c7; }

/* Input */
.pptc__label { display: block; font-size: 13px; font-weight: 600; color: #334155; margin-bottom: 8px; }
.pptc__input-row { display: flex; gap: 10px; margin-bottom: 6px; }
.pptc__input-wrap { position: relative; flex: 1; }
.pptc__input {
    width: 100%; padding: 11px 52px 11px 14px; font-size: 16px;
    font-family: 'Courier New', Courier, monospace; border: 1.5px solid #cbd5e1;
    border-radius: 10px; background: #f8fafc; color: #0f172a; outline: none;
    transition: border-color 0.2s, box-shadow 0.2s; -moz-appearance: textfield;
}
.pptc__input::-webkit-outer-spin-button,
.pptc__input::-webkit-inner-spin-button { -webkit-appearance: none; }
.pptc__input:focus { border-color: #0ea5e9; box-shadow: 0 0 0 3px rgba(14,165,233,0.1); background: #fff; }
.pptc__unit {
    position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
    font-size: 12px; font-weight: 700; color: #94a3b8; pointer-events: none;
}
.pptc__btn {
    padding: 11px 24px; background: linear-gradient(135deg,#0ea5e9,#0284c7); color: #fff;
    border: none; border-radius: 10px; font-size: 14px; font-weight: 700; cursor: pointer;
    font-family: inherit; white-space: nowrap; transition: opacity 0.15s;
}
.pptc__btn:hover { opacity: 0.9; }
.pptc__error { margin: 4px 0 0; font-size: 13px; color: #ef4444; }
.pptc__hint {
    display: flex; align-items: center; gap: 6px; margin-top: 10px;
    font-size: 12px; color: #94a3b8; background: #f8fafc; border: 1px solid #e2e8f0;
    border-radius: 8px; padding: 7px 12px;
}
.pptc__hint-icon { color: #0ea5e9; }
.pptc__hint-text { font-family: 'Courier New', monospace; font-weight: 600; }

/* Result bar */
.pptc__result-bar {
    display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
    background: #f0fdfa; border-top: 1.5px solid #99f6e4;
    border-bottom: 1.5px solid #99f6e4; padding: 12px 24px;
}
.pptc__result-label { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; color: #0f766e; }
.pptc__result-value { font-family: 'Courier New', monospace; font-size: 16px; font-weight: 900; color: #0d9488; }
.pptc__verify-badge { margin-left: auto; background: #dcfce7; color: #15803d; font-size: 11px; font-weight: 800; border-radius: 20px; padding: 3px 10px; letter-spacing: 0.5px; }

/* Steps panels */
.pptc__steps-wrap { padding: 20px 24px 0; }
.pptc__steps-panel { border: 1.5px solid; border-radius: 12px; overflow: hidden; }
.pptc__steps-panel--fwd { border-color: #99f6e4; }
.pptc__steps-panel--rev { border-color: #ddd6fe; }

.pptc__steps-header { padding: 10px 18px; font-weight: 800; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; }
.pptc__steps-header--fwd { background: #f0fdfa; color: #0f766e; border-bottom: 1.5px solid #99f6e4; }
.pptc__steps-header--rev { background: #faf5ff; color: #5b21b6; border-bottom: 1.5px solid #ddd6fe; }

/* Step item */
.pptc__step { padding: 14px 18px; border-bottom: 1px solid #f1f5f9; }
.pptc__step:last-child { border-bottom: none; }

.pptc__stp-label-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.pptc__stp-num {
    width: 22px; height: 22px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 800; flex-shrink: 0;
}
.pptc__steps-panel--fwd .pptc__stp-num { background: #ccfbf1; color: #0f766e; }
.pptc__steps-panel--rev .pptc__stp-num { background: #ede9fe; color: #5b21b6; }
.pptc__stp-label { font-size: 13px; font-weight: 600; color: #334155; }

.pptc__stp-formula {
    font-size: 12px; font-style: italic; color: #64748b; background: #f1f5f9;
    border-radius: 6px; padding: 4px 10px; margin-bottom: 8px;
    display: inline-block; font-family: 'Courier New', Courier, monospace;
}
.pptc__stp-calc { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; font-size: 13px; }
.pptc__stp-val { font-weight: 600; color: #334155; }
.pptc__stp-eq  { font-weight: 400; color: #94a3b8; }
.pptc__stp-arrow { color: #94a3b8; font-weight: 400; }

.pptc__stp-result { font-size: 13px; font-weight: 900; padding: 4px 12px; border-radius: 20px; display: inline-block; }
.pptc__steps-panel--fwd .pptc__stp-result { background: #ccfbf1; color: #0f766e; }
.pptc__steps-panel--rev .pptc__stp-result { background: #ede9fe; color: #5b21b6; }
.pptc__stp-result--final { font-size: 15px; padding: 6px 18px; box-shadow: 0 2px 10px rgba(0,0,0,0.1); }
.pptc__steps-panel--fwd .pptc__stp-result--final { background: linear-gradient(90deg,#0d9488,#14b8a6); color: #fff; }
.pptc__steps-panel--rev .pptc__stp-result--final { background: linear-gradient(90deg,#7c3aed,#a78bfa); color: #fff; }

/* Divider */
.pptc__steps-divider {
    display: flex; align-items: center; gap: 12px;
    background: #f1f5f9; padding: 10px 20px;
    border-top: 1.5px solid #e2e8f0; border-bottom: 1.5px solid #e2e8f0;
    margin: 20px 0 0;
}
.pptc__steps-divider::before, .pptc__steps-divider::after { content: ''; flex: 1; height: 1px; background: #cbd5e1; }
.pptc__steps-divider span { font-size: 11px; font-weight: 800; letter-spacing: 2px; text-transform: uppercase; color: #7c3aed; white-space: nowrap; }
#pptc-rev-wrap { padding-bottom: 20px; }

/* About */
.pptc__about {
    background: #fff; border: 1.5px solid #e2e8f0; border-radius: 16px;
    padding: 22px 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.pptc__about h3 { font-size: 16px !important; font-weight: 700 !important; color: #0f172a !important; margin: 0 0 10px !important; }
.pptc__about p { font-size: 13px; color: #64748b; line-height: 1.65; margin: 0 0 12px; }
.pptc__formula-box {
    background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px;
    padding: 12px; text-align: center; font-family: 'Courier New', monospace;
    font-size: 14px; font-weight: 700; color: #0f172a; margin-bottom: 12px;
}
.pptc__ref-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; margin-top: 14px; }
.pptc__ref-item { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px; padding: 10px; text-align: center; }
.pptc__ref-label { display: block; font-size: 11px; font-weight: 700; color: #64748b; margin-bottom: 3px; }
.pptc__ref-val { font-size: 13px; font-weight: 800; color: #0d9488; }
