.sw-utm-shell {
    overflow: hidden;
    border: 1px solid rgba(20, 72, 150, 0.12);
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 22px 58px rgba(18, 53, 96, 0.1);
}

.sw-utm-tabs {
    display: grid;
    padding: 8px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
    border-bottom: 1px solid #e7ecf3;
    background: #f4f7fb;
}

.sw-utm-tab {
    display: inline-flex;
    min-height: 48px;
    padding: 0 12px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 11px;
    color: #66758a;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.15;
    transition: background-color var(--transition), color var(--transition), box-shadow var(--transition);
}

.sw-utm-tab svg {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
}

.sw-utm-tab[aria-selected="true"] {
    background: #ffffff;
    box-shadow: 0 7px 18px rgba(18, 53, 96, 0.08);
    color: var(--primary);
}

.sw-utm-panel {
    padding: 22px;
}

.sw-utm-panel[hidden] {
    display: none;
}

.sw-utm-workspace {
    display: grid;
    gap: 24px;
}

.sw-utm-column {
    min-width: 0;
}

.sw-utm-column__head {
    margin-bottom: 20px;
}

.sw-utm-column__head h2 {
    margin: 0;
    color: var(--text-main);
    font-size: 21px;
    font-weight: 820;
    line-height: 1.25;
    letter-spacing: -0.025em;
}

.sw-utm-column__head p {
    margin-top: 7px;
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.55;
}

.sw-utm-form {
    display: grid;
    gap: 17px;
}

.sw-utm-field-grid {
    display: grid;
    gap: 17px;
}

.sw-utm-field {
    display: grid;
    gap: 7px;
}

.sw-utm-label {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    color: #28364a;
    font-size: 13px;
    font-weight: 780;
    line-height: 1.35;
}

.sw-utm-label small {
    color: #8b98aa;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.sw-utm-input,
.sw-utm-select,
.sw-utm-textarea {
    width: 100%;
    border: 1px solid #dbe3ed;
    border-radius: 11px;
    background: #ffffff;
    color: var(--text-main);
    font-size: 15px;
    line-height: 1.4;
    transition: border-color var(--transition), box-shadow var(--transition), background-color var(--transition);
}

.sw-utm-input,
.sw-utm-select {
    min-height: 48px;
    padding: 0 13px;
}

.sw-utm-select {
    padding-right: 38px;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    cursor: pointer;
}

.sw-utm-textarea {
    min-height: 104px;
    padding: 13px;
    resize: vertical;
}

.sw-utm-input,
.sw-utm-textarea {
    cursor: text;
}

.sw-utm-input::placeholder,
.sw-utm-textarea::placeholder {
    color: #a4afbd;
}

.sw-utm-input:hover,
.sw-utm-select:hover,
.sw-utm-textarea:hover {
    border-color: #bdcadb;
}

.sw-utm-input:focus,
.sw-utm-select:focus,
.sw-utm-textarea:focus {
    border-color: rgba(20, 72, 150, 0.56);
    box-shadow: 0 0 0 4px rgba(20, 72, 150, 0.09);
}

.sw-utm-field.is-invalid .sw-utm-input,
.sw-utm-field.is-invalid .sw-utm-select,
.sw-utm-field.is-invalid .sw-utm-textarea {
    border-color: #d94c5a;
    box-shadow: 0 0 0 4px rgba(217, 76, 90, 0.08);
}

.sw-utm-field-error {
    min-height: 17px;
    color: #c5303f;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.45;
}

.sw-utm-options {
    display: grid;
    padding: 16px;
    gap: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 13px;
    background: #f7f9fc;
}

.sw-utm-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: #46566c;
    font-size: 12px;
    font-weight: 680;
    line-height: 1.45;
    cursor: pointer;
}

.sw-utm-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.sw-utm-checkmark {
    position: relative;
    width: 19px;
    height: 19px;
    flex: 0 0 19px;
    border: 1px solid #bdcad9;
    border-radius: 6px;
    background: #ffffff;
    transition: background-color var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.sw-utm-checkmark::after {
    content: "";
    position: absolute;
    top: 4px;
    left: 6px;
    width: 4px;
    height: 7px;
    border: solid #ffffff;
    border-width: 0 2px 2px 0;
    opacity: 0;
    transform: rotate(45deg);
}

.sw-utm-option input:checked + .sw-utm-checkmark {
    border-color: var(--primary);
    background: var(--primary);
}

.sw-utm-option input:checked + .sw-utm-checkmark::after {
    opacity: 1;
}

.sw-utm-option input:focus-visible + .sw-utm-checkmark {
    box-shadow: 0 0 0 4px rgba(20, 72, 150, 0.12);
}

.sw-utm-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.sw-utm-actions .sw-tools-button {
    flex: 1 1 150px;
}

.sw-utm-result {
    min-height: 100%;
    padding: 20px;
    border: 1px solid #e1e8f1;
    border-radius: 16px;
    background: #f7f9fc;
}

.sw-utm-result__empty {
    display: flex;
    min-height: 250px;
    padding: 28px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.sw-utm-result__empty svg {
    width: 46px;
    height: 46px;
    margin-bottom: 16px;
    color: #8aa6cc;
}

.sw-utm-result__empty strong {
    color: #314056;
    font-size: 15px;
    font-weight: 800;
}

.sw-utm-result__empty span {
    max-width: 320px;
    margin-top: 7px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.55;
}

.sw-utm-result__content[hidden],
.sw-utm-result__empty[hidden] {
    display: none;
}

.sw-utm-result__label {
    display: block;
    margin-bottom: 8px;
    color: #53647b;
    font-size: 11px;
    font-weight: 850;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.sw-utm-output {
    min-height: 132px;
    background: #ffffff;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 12px;
    line-height: 1.55;
    word-break: break-all;
}

.sw-utm-result__actions {
    display: grid;
    margin-top: 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
}

.sw-utm-result__actions .sw-tools-button {
    min-height: 44px;
    padding: 0 12px;
    font-size: 12px;
}

.sw-utm-meta {
    display: flex;
    margin-top: 16px;
    flex-wrap: wrap;
    gap: 8px;
}

.sw-utm-meta span {
    display: inline-flex;
    min-height: 28px;
    padding: 0 9px;
    align-items: center;
    border-radius: 999px;
    background: #eaf1fb;
    color: #3d5f90;
    font-size: 10px;
    font-weight: 800;
}

.sw-utm-breakdown {
    display: grid;
    margin-top: 18px;
    gap: 8px;
}

.sw-utm-breakdown__row {
    display: grid;
    padding: 10px 11px;
    grid-template-columns: 100px minmax(0, 1fr);
    gap: 10px;
    border-radius: 9px;
    background: #ffffff;
    font-size: 11px;
    line-height: 1.45;
}

.sw-utm-breakdown__row dt {
    color: #59708e;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-weight: 800;
}

.sw-utm-breakdown__row dd {
    min-width: 0;
    overflow-wrap: anywhere;
    color: #26364d;
    font-weight: 700;
}

.sw-utm-check-result {
    margin-top: 20px;
}

.sw-utm-check-result[hidden] {
    display: none;
}

.sw-utm-verdict {
    display: flex;
    padding: 16px;
    align-items: flex-start;
    gap: 12px;
    border: 1px solid #dce6f2;
    border-radius: 13px;
    background: #f7f9fc;
}

.sw-utm-verdict__icon {
    display: inline-flex;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #e7eef8;
    color: #4f6f9c;
}

.sw-utm-verdict__icon svg {
    width: 19px;
    height: 19px;
}

.sw-utm-verdict--success {
    border-color: #bfe7d2;
    background: #f1fbf6;
}

.sw-utm-verdict--success .sw-utm-verdict__icon {
    background: #d8f4e6;
    color: #08764a;
}

.sw-utm-verdict--warning {
    border-color: #f2d89a;
    background: #fffaf0;
}

.sw-utm-verdict--warning .sw-utm-verdict__icon {
    background: #ffefc7;
    color: #9a6400;
}

.sw-utm-verdict--error {
    border-color: #f1c1c7;
    background: #fff5f6;
}

.sw-utm-verdict--error .sw-utm-verdict__icon {
    background: #f9dce0;
    color: #b52d3d;
}

.sw-utm-verdict strong {
    display: block;
    color: var(--text-main);
    font-size: 14px;
    font-weight: 820;
    line-height: 1.35;
}

.sw-utm-verdict p {
    margin-top: 4px;
    color: #5e6e83;
    font-size: 12px;
    line-height: 1.5;
}

.sw-utm-issues {
    display: grid;
    margin-top: 14px;
    gap: 8px;
}

.sw-utm-issue {
    display: flex;
    padding: 11px 12px;
    align-items: flex-start;
    gap: 9px;
    border-radius: 10px;
    background: #f7f9fc;
    color: #4f6077;
    font-size: 12px;
    font-weight: 650;
    line-height: 1.45;
}

.sw-utm-issue::before {
    content: "";
    width: 7px;
    height: 7px;
    margin-top: 5px;
    flex: 0 0 7px;
    border-radius: 50%;
    background: #e0a11b;
}

.sw-utm-issue--error::before {
    background: #d94c5a;
}

.sw-utm-table-wrap {
    margin-top: 16px;
    overflow-x: auto;
    border: 1px solid #e0e7f0;
    border-radius: 12px;
}

.sw-utm-table {
    width: 100%;
    min-width: 540px;
    border-collapse: collapse;
    background: #ffffff;
}

.sw-utm-table th,
.sw-utm-table td {
    padding: 12px 14px;
    border-bottom: 1px solid #e8edf3;
    text-align: left;
    vertical-align: top;
}

.sw-utm-table tr:last-child td {
    border-bottom: 0;
}

.sw-utm-table th {
    background: #f5f8fc;
    color: #68778b;
    font-size: 10px;
    font-weight: 850;
    letter-spacing: 0.045em;
    text-transform: uppercase;
}

.sw-utm-table td {
    color: #34445a;
    font-size: 12px;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.sw-utm-table code {
    color: var(--primary);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 11px;
    font-weight: 750;
}

.sw-utm-clean {
    display: grid;
    margin-top: 16px;
    gap: 9px;
}

.sw-utm-clean__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
}

.sw-utm-clean__row .sw-utm-input {
    min-width: 0;
    background: #f7f9fc;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 11px;
}

.sw-utm-clean__row .sw-tools-button {
    min-height: 48px;
    padding: 0 14px;
}

.sw-utm-guide-grid {
    display: grid;
    gap: 14px;
}

.sw-utm-guide-card {
    padding: 22px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #ffffff;
}

.sw-utm-guide-card__number {
    display: inline-flex;
    width: 32px;
    height: 32px;
    margin-bottom: 16px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #edf4fe;
    color: var(--primary);
    font-size: 12px;
    font-weight: 850;
}

.sw-utm-guide-card h3 {
    margin: 0;
    color: var(--text-main);
    font-size: 16px;
    font-weight: 820;
    line-height: 1.35;
}

.sw-utm-guide-card p {
    margin-top: 8px;
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.6;
}

.sw-utm-params {
    display: grid;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #ffffff;
}

.sw-utm-param {
    display: grid;
    padding: 17px 19px;
    gap: 5px;
    border-bottom: 1px solid #e8edf3;
}

.sw-utm-param:last-child {
    border-bottom: 0;
}

.sw-utm-param code {
    color: var(--primary);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 12px;
    font-weight: 850;
}

.sw-utm-param span {
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.55;
}

.sw-utm-faq {
    display: grid;
    gap: 10px;
}

.sw-utm-faq details {
    border: 1px solid #e1e8f0;
    border-radius: 14px;
    background: #ffffff;
}

.sw-utm-faq summary {
    position: relative;
    padding: 18px 48px 18px 18px;
    color: #26364c;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.4;
    list-style: none;
    cursor: pointer;
}

.sw-utm-faq summary::-webkit-details-marker {
    display: none;
}

.sw-utm-faq summary::after {
    content: "+";
    position: absolute;
    top: 50%;
    right: 18px;
    color: var(--primary);
    font-size: 22px;
    font-weight: 500;
    line-height: 1;
    transform: translateY(-50%);
}

.sw-utm-faq details[open] summary::after {
    content: "−";
}

.sw-utm-faq p {
    padding: 0 18px 18px;
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.65;
}

@media (min-width: 641px) {
    .sw-utm-tabs {
        display: flex;
        padding: 10px;
    }

    .sw-utm-tab {
        min-width: 200px;
        padding: 0 20px;
    }

    .sw-utm-panel {
        padding: 30px;
    }

    .sw-utm-field-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sw-utm-actions .sw-tools-button {
        flex: 0 0 auto;
    }

    .sw-utm-guide-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .sw-utm-param {
        grid-template-columns: 130px minmax(0, 1fr);
        align-items: baseline;
        gap: 18px;
    }
}

@media (min-width: 960px) {
    .sw-utm-panel {
        padding: 36px;
    }

    .sw-utm-workspace {
        grid-template-columns: minmax(0, 1.12fr) minmax(340px, 0.88fr);
        gap: 36px;
        align-items: stretch;
    }

    .sw-utm-column--result {
        padding-left: 36px;
        border-left: 1px solid #e6ebf2;
    }
}

@media (max-width: 420px) {
    .sw-utm-result__actions,
    .sw-utm-clean__row {
        grid-template-columns: minmax(0, 1fr);
    }
}
