.tools-hero {
    min-height: 180px;
}

.tools-shell .card,
.tools-shell .btn,
.tools-shell .form-control,
.tools-shell textarea,
.tools-shell .tools-country-list,
.tools-shell .tools-country-code,
.tools-shell .tools-count-bubble,
.tools-shell .tools-inline-toggle {
    border-radius: 5px;
}

.tools-section-title {
    color: var(--status-blue-dark);
    font-size: 1.1rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.tools-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.tools-count-bubble {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.35rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1;
    color: #166534;
    background: #dcfce7;
    border: 1px solid #86efac;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.tools-count-bubble.is-active {
    color: #fff;
    background: #dc2626;
    border-color: #dc2626;
}

.tools-content-container {
    width: 100%;
    max-width: 1240px;
}

.tools-list-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: nowrap;
    margin-bottom: 0.5rem;
}

.tools-list-heading-main {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.tools-list-heading .form-label {
    white-space: nowrap;
    flex: 0 0 auto;
}

.tools-selected-inline {
    white-space: nowrap;
    min-width: 0;
    text-align: right;
}

.tools-inline-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    border: 0;
    border-radius: 5px;
    padding: 0;
    background: transparent;
}

.tools-inline-toggle .form-check-input {
    margin: 0;
}

.tools-inline-toggle .form-check-label {
    font-size: 0.78rem;
    color: var(--status-gray-700);
    white-space: nowrap;
}

.tools-card {
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.tools-country-list {
    border: 1px solid var(--status-gray-200);
    border-radius: 5px;
    background: #fff;
    max-height: 360px;
    overflow-y: auto;
}

.tools-country-item {
    border-bottom: 1px solid var(--status-gray-100);
}

.tools-country-item:last-child {
    border-bottom: 0;
}

.tools-country-label {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.5rem 0.75rem;
    margin: 0;
    cursor: pointer;
    font-size: 0.93rem;
}

.tools-country-label:hover {
    background: #f8fafc;
}

.tools-country-code {
    font-weight: 700;
    font-size: 0.75rem;
    color: var(--status-blue-dark);
    background: rgba(29, 78, 216, 0.08);
    border-radius: 5px;
    padding: 0.1rem 0.4rem;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.tools-country-item.is-selected .tools-country-code {
    color: #fff;
    background: #dc2626;
}

.tools-country-name {
    color: var(--status-gray-700);
}

.tools-output {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', monospace;
    font-size: 0.84rem;
    line-height: 1.5;
    height: 241px;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.tools-actions .btn {
    font-size: 0.9rem;
}

.tools-password-card .btn {
    font-size: 0.9rem;
}


.tools-ip-controls .btn {
    flex: 1 1 0;
    font-size: 0.9rem;
}

@media (min-width: 576px) {
    .tools-ip-controls .btn {
        flex: 0 0 auto;
    }
}

.tools-empty-state {
    padding: 0.8rem;
    color: var(--status-gray-600);
    font-size: 0.85rem;
}

.tools-strength-wrap {
    border: 1px solid var(--status-gray-200);
    border-radius: 5px;
    padding: 0.65rem 0.75rem;
    background: #fff;
}

.tools-password-length-control {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: nowrap;
}

.tools-password-length-control .form-range {
    flex: 1 1 auto;
    min-width: 0;
}

.tools-password-length-control #password-length-input {
    flex: 0 0 5.25rem;
    width: 5.25rem;
}

.tools-strength-meter {
    margin-top: 0.45rem;
    height: 0.52rem;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}

.tools-strength-meter__bar {
    height: 100%;
    width: 0;
    transition: width 0.2s ease, background-color 0.2s ease;
    background: #94a3b8;
}

.tools-strength-meter__bar.is-weak {
    background: #dc2626;
}

.tools-strength-meter__bar.is-medium {
    background: #f59e0b;
}

.tools-strength-meter__bar.is-strong {
    background: #10b981;
}

.tools-strength-meter__bar.is-very-strong {
    background: #2563eb;
}

@media (max-width: 575.98px) {
    .tools-ip-controls {
        flex-wrap: nowrap;
    }

    .tools-password-output-group {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.5rem;
    }

    .tools-password-output-group #password-output {
        grid-column: 1 / -1;
        width: 100%;
        min-width: 0;
        border-radius: 5px !important;
    }

    .tools-password-output-group #password-copy-btn,
    .tools-password-output-group #password-regenerate-btn {
        width: 100%;
        border-radius: 5px !important;
    }
}

@media (min-width: 992px) {
    .tools-generator-row > .tools-list-column {
        display: flex;
        flex-direction: column;
    }

    .tools-generator-row > .tools-output-column {
        padding-top: 2.5rem;
    }

    .tools-generator-row > .tools-list-column .tools-country-list {
        flex: 0 1 auto;
        max-height: 313px;
    }

    .tools-actions {
        flex-wrap: nowrap;
    }

    .tools-actions .btn {
        flex: 1 1 0;
        width: 50%;
    }
}

@media (max-width: 767.98px) {
    .tools-section-title {
        white-space: nowrap;
        font-size: 0.98rem;
    }

    .tools-section-heading {
        flex-wrap: wrap;
    }

    .tools-list-heading {
        font-size: 0.95rem;
        flex-wrap: nowrap;
    }

    .tools-list-heading-main {
        flex-wrap: nowrap;
        width: 100%;
        justify-content: space-between;
        gap: 0.35rem;
    }

    .tools-inline-toggle .form-check-label {
        font-size: 0.72rem;
    }

    .tools-selected-inline {
        white-space: normal;
    }

    .tools-country-list {
        max-height: 260px;
    }

    .tools-actions {
        flex-wrap: nowrap;
    }

    .tools-actions .btn {
        flex: 1 1 0;
        width: 100%;
    }
}

.tools-ip-results {
    border: 1px solid var(--status-gray-200);
    border-radius: 5px;
    background: #fff;
    overflow: hidden;
}

.tools-ip-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid var(--status-gray-100);
}

.tools-ip-result-item:last-child {
    border-bottom: 0;
}

.tools-ip-result-label {
    font-size: 0.85rem;
    color: var(--status-gray-600);
    font-weight: 600;
}

.tools-ip-result-value {
    font-size: 0.92rem;
    color: var(--status-blue-dark);
    font-weight: 600;
    text-align: right;
    word-break: break-word;
}

.tools-ip-actions .btn {
    flex: 0 0 auto;
    width: auto;
}

@media (max-width: 767.98px) {
    .tools-ip-result-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .tools-ip-result-value {
        text-align: left;
    }
}
