.customers-modal {
    display: none;
    z-index: 10004;
}

.customers-modal.is-open {
    display: flex;
}

.customers-modal__box {
    background: #fff;
    max-width: 1000px;
}

.customers-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 25px;
}

.customers-toolbar form {
    margin: 0;
}

.customers-search,
.customers-input {
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1rem;
    padding: 12px 15px;
}

.customers-search {
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
    flex: 1;
    min-width: 250px;
    outline: none;
}

.customers-input {
    padding: 8px;
}

.customers-input--password {
    font-size: 0.85rem;
}

.customers-btn {
    border: 0;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 700;
    padding: 12px 20px;
}

.customers-btn--success {
    background: var(--admin-success);
    box-shadow: 0 2px 5px rgba(40, 167, 69, 0.3);
    color: #fff;
    height: 100%;
    white-space: nowrap;
}

.customers-btn--danger {
    background: var(--admin-danger);
    color: #fff;
    font-size: 0.85rem;
    padding: 8px 15px;
}

.customers-btn--gold {
    background: var(--admin-secondary);
    box-shadow: 0 2px 4px rgba(212, 175, 55, 0.3);
    color: #fff;
    padding: 8px 15px;
}

.customers-alert {
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 15px;
    padding: 10px;
}

.customers-alert--danger {
    background: #f8d7da;
    color: #721c24;
}

.customers-danger-zone {
    align-items: center;
    background: #f8d7da;
    border-left: 4px solid var(--admin-danger);
    border-radius: 5px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: space-between;
    margin-bottom: 25px;
    padding: 15px;
}

.customers-danger-zone__text {
    flex: 1;
    min-width: 200px;
}

.customers-danger-zone__text p {
    color: #721c24;
    font-size: 0.85rem;
    margin: 0;
}

.customers-danger-zone__text p:first-child {
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.customers-danger-zone__form {
    align-items: center;
    display: flex;
    gap: 10px;
    margin: 0;
}

.customers-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.customers-empty {
    color: #888;
    font-style: italic;
    padding: 30px;
    text-align: center;
}

.customers-empty--small {
    font-size: 0.85rem;
    padding: 0;
    text-align: left;
}

.customer-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.customer-card.is-hidden {
    display: none;
}

.customer-card__header {
    align-items: center;
    background: #fafbfc;
    border: 0;
    cursor: pointer;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: space-between;
    padding: 20px;
    text-align: left;
    width: 100%;
}

.customer-card.is-open .customer-card__header {
    border-bottom: 1px solid #eee;
}

.customer-card__identity {
    align-items: center;
    display: flex;
    gap: 15px;
}

.customer-avatar {
    align-items: center;
    background: var(--admin-secondary);
    border-radius: 50%;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
    color: #fff;
    display: flex;
    flex-shrink: 0;
    font-size: 1.5rem;
    font-weight: 700;
    height: 50px;
    justify-content: center;
    text-transform: uppercase;
    width: 50px;
}

.customer-card__name {
    color: var(--admin-primary);
    display: block;
    font-size: 1.2rem;
    font-weight: 700;
}

.customer-tags {
    display: block;
    margin-top: 3px;
}

.customer-tag {
    background: var(--admin-secondary);
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(212, 175, 55, 0.4);
    color: #fff;
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    margin: 0 5px 5px 0;
    padding: 3px 10px;
    text-transform: uppercase;
}

.customer-contact {
    color: #666;
    display: flex;
    flex-wrap: wrap;
    font-size: 0.85rem;
    gap: 10px;
    margin-top: 3px;
}

.customer-card__stats {
    align-items: center;
    display: flex;
    gap: 25px;
    text-align: right;
}

.customer-card__label {
    color: #888;
    display: block;
    font-size: 0.75rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.customer-card__ltv {
    color: var(--admin-success);
    font-size: 1.2rem;
}

.customer-pill {
    background: #e9ecef;
    border-radius: 12px;
    color: #444;
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    margin-right: 5px;
    padding: 3px 8px;
}

.customer-pill--info {
    background: #e8f4f8;
    color: var(--admin-info);
}

.customer-chevron {
    color: #ccc;
    font-size: 1.2rem;
    transition: transform 0.3s;
}

.customer-card.is-open .customer-chevron {
    transform: rotate(180deg);
}

.customer-card__body {
    background: #fff;
    padding: 20px;
}

.customer-tags-box {
    background: #fcfcfc;
    border: 1px solid #f0f0f0;
    border-left: 3px solid var(--admin-secondary);
    border-radius: 6px;
    margin-bottom: 20px;
    padding: 15px;
}

.customer-tags-form {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
}

.customer-tags-form label {
    color: #333;
    flex: 1;
    font-size: 0.9rem;
    font-weight: 700;
    min-width: 240px;
}

.customer-tags-form input {
    display: block;
    margin-top: 6px;
    width: 100%;
}

.customer-delete-form {
    border-top: 1px dashed #e0e0e0;
    margin: 15px 0 0;
    padding-top: 15px;
    text-align: right;
}

.customers-link-danger {
    background: transparent;
    border: 0;
    color: var(--admin-danger);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0;
    text-decoration: underline;
}

.customer-history-grid {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.customer-history {
    border: 1px solid #f0f0f0;
    border-radius: 6px;
    padding: 15px;
}

.customer-history--orders {
    background: #fcfcfc;
}

.customer-history--requests {
    background: #e8f4f8;
    border-color: #bce0ea;
}

.customer-history h4 {
    border-bottom: 2px solid var(--admin-secondary);
    color: var(--admin-primary);
    display: inline-block;
    margin: 0 0 15px;
    padding-bottom: 5px;
}

.customer-history--requests h4 {
    border-bottom-color: var(--admin-info);
    color: var(--admin-info);
}

.customer-history-item {
    border-bottom: 1px solid #eee;
    color: #555;
    font-size: 0.85rem;
    margin-bottom: 8px;
    padding-bottom: 8px;
}

.customer-history--requests .customer-history-item {
    border-bottom-color: rgba(23, 162, 184, 0.2);
}

.customer-history-item__head {
    display: flex;
    justify-content: space-between;
    margin-bottom: 3px;
}

.customer-history-item__price {
    align-items: center;
    color: var(--admin-success);
    display: flex;
    font-weight: 700;
}

.customer-muted,
.customer-deposit {
    color: #888;
    font-size: 0.75rem;
}

.customer-paid-badge {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 10px;
    color: #155724;
    font-size: 0.7rem;
    margin-left: 5px;
    padding: 1px 5px;
}

.customer-deposit {
    margin-left: 5px;
}

.customer-request-service {
    color: var(--admin-info);
    font-size: 0.75rem;
    font-weight: 700;
}

.customer-history-item__quote {
    color: #555;
    font-style: italic;
}

@media (max-width: 760px) {
    .customers-danger-zone__form,
    .customer-card__stats {
        align-items: stretch;
        flex-direction: column;
        text-align: left;
    }
}
