/**
 * PDF Compressor Styles
 * PDF Compressor styles for localized pages
 */

.pdcmp-tool-intro {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 12px;
}

.pdcmp-tool-lead {
    margin: 0;
    font-size: 14px;
    line-height: 1.55;
    color: #5f5a56;
}

.pdcmp-workbench {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas:
        "stage upload"
        "strength process"
        "selection overview"
        "warning warning"
        "details details"
        "disclaimer disclaimer";
    align-items: start;
    gap: 12px;
}

.pdcmp-stage-section,
.pdcmp-summary-section {
    background: #fffdf9;
    border: 1px solid #e8e0d2;
    border-radius: 16px;
    box-shadow: 0 6px 18px rgba(53, 44, 25, 0.045);
}

.pdcmp-stage-section {
    grid-area: stage;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scroll-margin-top: calc(var(--header-height, 56px) + 16px);
}

.pdcmp-side-column {
    display: contents;
}

.pdcmp-summary-section {
    grid-area: details;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scroll-margin-top: calc(var(--header-height, 56px) + 16px);
}

.pdcmp-side-grid {
    display: contents;
}

.pdcmp-panel-card {
    background: #fffdf9;
    border: 1px solid #e8e0d2;
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(53, 44, 25, 0.04);
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.pdcmp-upload-card {
    grid-area: upload;
}

.pdcmp-strength-card {
    grid-area: strength;
}

.pdcmp-process-panel {
    grid-area: process;
    justify-content: stretch;
}

.pdcmp-selection-card {
    grid-area: selection;
}

.pdcmp-overview-card {
    grid-area: overview;
}

.pdcmp-warning-panel {
    grid-area: warning;
}

.pdcmp-disclaimer {
    grid-area: disclaimer;
}

.pdcmp-section-title {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 700;
    color: #2f2a24;
}

.pdcmp-section-title i {
    color: #b8860b;
}

.pdcmp-section-lead,
.pdcmp-summary-note,
.pdcmp-profile-note,
.pdcmp-warning-box p {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: #6a655f;
}

.pdcmp-stage-head,
.pdcmp-section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.pdcmp-stage-actions {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.pdcmp-preview-page-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pdcmp-preview-page-field label {
    font-size: 11px;
    font-weight: 700;
    color: #6a655f;
}

.pdcmp-page-input-row {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.pdcmp-page-input,
.pdcmp-upload-input {
    font: inherit;
}

.pdcmp-page-input {
    width: 64px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid #d8cfbf;
    background: #fff;
    font-size: 13px;
    color: #2f2a24;
}

.pdcmp-page-total {
    font-size: 12px;
    color: #7a736a;
}

.pdcmp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 14px;
    border-radius: 12px;
    border: 1px solid transparent;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease, color 0.16s ease;
}

.pdcmp-btn:hover:not(:disabled) {
    transform: translateY(-1px);
}

.pdcmp-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pdcmp-btn-primary {
    background: linear-gradient(135deg, #c89a1c 0%, #b8860b 100%);
    color: #fff;
    box-shadow: 0 6px 14px rgba(184, 134, 11, 0.18);
}

.pdcmp-btn-secondary {
    background: #fff8e8;
    border-color: #e6d29b;
    color: #7b5414;
}

.pdcmp-btn-ghost {
    background: #fdfbf7;
    border-color: #ded4c6;
    color: #5b544c;
}

.pdcmp-waiting {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 14px;
    background: #fffaf0;
    border: 1px solid #f0dca1;
}

.pdcmp-waiting.is-error {
    background: #fff2f0;
    border-color: #f0bbb4;
}

.pdcmp-waiting-icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(184, 134, 11, 0.12);
    color: #b8860b;
    font-size: 16px;
}

.pdcmp-waiting.is-error .pdcmp-waiting-icon {
    background: rgba(199, 84, 71, 0.12);
    color: #c75447;
}

.pdcmp-waiting-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pdcmp-waiting-title {
    font-size: 14px;
    font-weight: 700;
    color: #2f2a24;
}

.pdcmp-waiting-desc {
    margin: 0;
    font-size: 12px;
    line-height: 1.5;
    color: #6a655f;
}

.pdcmp-stage-body {
    min-height: 0;
}

.pdcmp-empty-state,
.pdcmp-preview-pane {
    display: flex;
    flex-direction: column;
    gap: 16px;
    height: 100%;
}

.pdcmp-preview-empty {
    min-height: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 20px 18px;
    border-radius: 14px;
    border: 1px dashed #d7cba9;
    background: #fbf6eb;
    text-align: center;
}

.pdcmp-preview-empty-icon {
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient(135deg, #c89a1c 0%, #b8860b 100%);
    color: #fff;
    font-size: 22px;
}

.pdcmp-preview-empty strong {
    font-size: 16px;
    color: #2f2a24;
}

.pdcmp-preview-empty p {
    margin: 0;
    max-width: 420px;
    font-size: 13px;
    line-height: 1.55;
    color: #6a655f;
}

.pdcmp-upload-block {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pdcmp-upload-card .pdcmp-upload-area {
    min-height: 126px;
}

.pdcmp-upload-area {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 150px;
    padding: 18px 16px;
    border-radius: 14px;
    border: 2px dashed #dacda7;
    background: #fbf6eb;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.pdcmp-inline-notes {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pdcmp-inline-note {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #e7dece;
    font-size: 11px;
    line-height: 1;
    color: #5f5a56;
    white-space: nowrap;
}

.pdcmp-inline-note i {
    color: #b8860b;
}

.pdcmp-upload-area:hover,
.pdcmp-upload-area.is-dragover {
    border-color: #b8860b;
    box-shadow: 0 8px 18px rgba(184, 134, 11, 0.10);
    transform: translateY(-1px);
}

.pdcmp-upload-icon {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: linear-gradient(135deg, #c89a1c 0%, #b8860b 100%);
    color: #fff;
    font-size: 20px;
}

.pdcmp-upload-text {
    font-size: 15px;
    font-weight: 800;
    color: #2f2a24;
}

.pdcmp-upload-hint {
    font-size: 12px;
    line-height: 1.5;
    color: #6a655f;
}

.pdcmp-upload-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.pdcmp-empty-note-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.pdcmp-empty-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 11px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #ece2ce;
    font-size: 12px;
    line-height: 1.45;
    color: #5f5a56;
}

.pdcmp-empty-note i {
    color: #b8860b;
    margin-top: 2px;
}

.pdcmp-preview-shell {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 184px;
    padding: 12px;
    border-radius: 14px;
    background: #f7f1e6;
    border: 1px solid #e5dccb;
    overflow: auto;
}

.pdcmp-profile-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border-radius: 999px;
    background: rgba(47, 42, 36, 0.9);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
}

.pdcmp-preview-canvas {
    max-width: 100%;
    max-height: 160px;
    height: auto;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.10);
    border-radius: 8px;
    background: #fff;
}

.pdcmp-preview-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pdcmp-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #ece2ce;
    font-size: 12px;
    color: #5c554b;
}

.pdcmp-meta-item i {
    color: #b8860b;
}

.pdcmp-profile-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.pdcmp-strength-card .pdcmp-profile-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.pdcmp-profile-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid #ddd4c7;
    background: #fff;
    text-align: left;
    cursor: pointer;
    transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.pdcmp-profile-card:hover,
.pdcmp-profile-card.is-active {
    border-color: #d4af37;
    box-shadow: 0 8px 16px rgba(212, 175, 55, 0.10);
    transform: translateY(-1px);
}

.pdcmp-profile-name {
    font-size: 14px;
    font-weight: 800;
    color: #2f2a24;
}

.pdcmp-profile-sub {
    font-size: 12px;
    color: #6a655f;
    line-height: 1.4;
}

.pdcmp-profile-panel {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    border-radius: 14px;
    background: #fbf6eb;
    border: 1px solid #ead9a5;
}

.pdcmp-selection-card .pdcmp-profile-panel,
.pdcmp-overview-card .pdcmp-summary-grid {
    height: 100%;
}

.pdcmp-overview-card .pdcmp-summary-note {
    margin-top: auto;
}

.pdcmp-profile-panel-head {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pdcmp-profile-panel-head strong {
    font-size: 14px;
    color: #2f2a24;
}

.pdcmp-profile-panel-head span {
    font-size: 12px;
    color: #6a655f;
    line-height: 1.4;
}

.pdcmp-profile-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.pdcmp-profile-stat {
    padding: 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid #efe4cd;
}

.pdcmp-profile-stat-label {
    display: block;
    margin-bottom: 4px;
    font-size: 11px;
    color: #7a736a;
}

.pdcmp-profile-stat strong {
    font-size: 13px;
    color: #2f2a24;
}

.pdcmp-action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pdcmp-action-row-single {
    display: block;
    width: 100%;
}

.pdcmp-action-row-single .pdcmp-btn {
    display: flex;
    width: 100%;
    flex: 1 1 100%;
}

.pdcmp-process-panel .pdcmp-action-row-single {
    display: flex;
    flex: 1 1 auto;
}

.pdcmp-process-panel .pdcmp-action-row-single .pdcmp-btn {
    min-height: 100%;
    height: 100%;
    padding: 12px 18px;
}

.pdcmp-warning-box,
.pdcmp-disclaimer {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px;
    padding: 12px 13px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #e9e1d3;
}

.pdcmp-warning-panel .pdcmp-warning-box {
    padding: 0;
    border: 0;
    background: transparent;
}

.pdcmp-warning-box i,
.pdcmp-disclaimer i {
    color: #b8860b;
    font-size: 16px;
    margin-top: 2px;
}

.pdcmp-warning-box strong,
.pdcmp-disclaimer strong {
    display: block;
    margin-bottom: 3px;
    font-size: 13px;
    color: #2f2a24;
}

.pdcmp-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.pdcmp-summary-card {
    padding: 12px;
    border-radius: 14px;
    background: #fff;
    border: 1px solid #e7ddce;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.pdcmp-summary-card-accent {
    background: #fff9e8;
    border-color: #e7cb75;
}

.pdcmp-summary-card.is-positive {
    border-color: #59ab79;
    background: #f2fbf5;
}

.pdcmp-summary-card.is-warning {
    border-color: #d98039;
    background: #fff5ec;
}

.pdcmp-summary-label {
    font-size: 12px;
    font-weight: 700;
    color: #7a736a;
    margin-bottom: 6px;
}

.pdcmp-summary-value {
    font-size: 20px;
    font-weight: 800;
    color: #2f2a24;
    line-height: 1.2;
}

.pdcmp-summary-value-small {
    font-size: 14px;
    line-height: 1.3;
}

.pdcmp-result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pdcmp-table-wrap {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid #e7ddce;
    background: #fff;
}

.pdcmp-info-table {
    width: 100%;
    border-collapse: collapse;
}

.pdcmp-info-table th,
.pdcmp-info-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #efe7da;
    font-size: 12px;
    line-height: 1.45;
    text-align: left;
    vertical-align: top;
}

.pdcmp-info-table th {
    width: 104px;
    color: #5c554b;
    background: #fcf8ef;
    font-weight: 700;
}

.pdcmp-info-table tr:last-child th,
.pdcmp-info-table tr:last-child td {
    border-bottom: 0;
}

.pdcmp-hidden {
    display: none !important;
}

@media (max-width: 900px) {
    .pdcmp-workbench {
        grid-template-columns: 1fr;
        grid-template-areas:
            "stage"
            "upload"
            "strength"
            "process"
            "selection"
            "overview"
            "warning"
            "details"
            "disclaimer";
    }

    .pdcmp-strength-card .pdcmp-profile-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .pdcmp-stage-section,
    .pdcmp-control-section,
    .pdcmp-summary-section {
        padding: 14px;
        border-radius: 14px;
    }

    .pdcmp-stage-head,
    .pdcmp-section-head,
    .pdcmp-stage-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .pdcmp-empty-note-grid,
    .pdcmp-profile-grid,
    .pdcmp-profile-stats,
    .pdcmp-summary-grid {
        grid-template-columns: 1fr;
    }

    .pdcmp-action-row {
        flex-direction: column;
    }

    .pdcmp-result-actions {
        flex-direction: column;
    }

    .pdcmp-btn {
        width: 100%;
    }

    .pdcmp-preview-shell {
        min-height: 200px;
        padding: 12px;
    }

    .pdcmp-summary-value {
        font-size: 18px;
    }
}
