﻿
/* استایل‌های اختصاصی صفحه آدرس‌ها */
.addresses-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

.addresses-table th {
    background: #f8f9fa;
    padding: 15px;
    text-align: right;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #e9ecef;
}

.addresses-table td {
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: top;
}

.addresses-table tr:last-child td {
    border-bottom: none;
}

.addresses-table tr:hover {
    background: #f8f9fa;
}

.address-info {
    line-height: 1.6;
}

.address-main {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.default-indicator {
    color: #27ae60;
    font-size: 14px;
    background: #e8f6ef;
    padding: 2px 8px;
    border-radius: 4px;
}

.address-detail {
    color: #6c757d;
    font-size: 14px;
    margin: 3px 0;
}

    .address-detail i {
        width: 16px;
        margin-left: 8px;
        color: #3498db;
    }

.table-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-start;
}

.btn-edit, .btn-delete {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.btn-edit {
    background: #3498db;
    color: white;
}

    .btn-edit:hover {
        background: #2980b9;
    }

.btn-delete {
    background: #e74c3c;
    color: white;
}

    .btn-delete:hover {
        background: #c0392b;
    }

/* مودال */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 700px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

    .modal-header h2 {
        margin: 0;
        color: #2c3e50;
    }

.close {
    color: #6c757d;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

    .close:hover {
        color: #e74c3c;
    }

.modal-body {
    padding: 20px;
}

.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.form-group {
    flex: 1;
}

    .form-group.full-width {
        flex: 100%;
    }

    .form-group label {
        display: block;
        margin-bottom: 5px;
        font-weight: 600;
        color: #2c3e50;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        width: 100%;
        padding: 10px;
        border: 1px solid #ddd;
        border-radius: 4px;
        font-size: 14px;
        transition: border-color 0.3s ease;
        font-family: inherit;
    }

        .form-group input:focus,
        .form-group select:focus,
        .form-group textarea:focus {
            outline: none;
            border-color: #3498db;
            box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
        }

    .form-group textarea {
        resize: vertical;
        min-height: 100px;
    }

.checkbox-container {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-top: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
}

    .checkbox-container input {
        width: auto;
        margin-left: 8px;
    }

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.btn-cancel, .btn-save {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-cancel {
    background: #95a5a6;
    color: white;
}

    .btn-cancel:hover {
        background: #7f8c8d;
    }

.btn-save {
    background: #27ae60;
    color: white;
}

    .btn-save:hover {
        background: #219a52;
    }

.empty-state {
    text-align: center;
    padding: 40px;
    color: #6c757d;
}

    .empty-state i {
        font-size: 48px;
        margin-bottom: 15px;
        color: #bdc3c7;
    }

@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 10px;
    }

    .table-actions {
        flex-direction: column;
    }

    .addresses-table {
        font-size: 14px;
    }

        .addresses-table th,
        .addresses-table td {
            padding: 10px;
        }
}

