/* Base Styles */
.post-alert-container {
    font-family:
        -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu,
        Cantarell, sans-serif;
}

/* Subscribe Button Styles */
.post-alert-subscribe,
.post-alert-subscribed {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 8px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.post-alert-subscribe {
    background: var(--pa-gradient-primary);
    color: var(--pa-bg-white);
    border: none;
    cursor: pointer;
    box-shadow: var(--pa-shadow-button);
}
.post-alert-subscribe.is-subscribed {
    background: var(--pa-gradient-secondary);
    color: var(--pa-text-dark);
}
.post-alert-subscribe:hover {
    transform: translateY(-1px);
    box-shadow: var(--pa-shadow-lg);
}

.post-alert-subscribed {
    background: var(--pa-bg-light);
    color: var(--pa-text-muted);
    border: 1px solid var(--pa-border-light);
    cursor: not-allowed;
}

.post-alert-icon {
    margin-right: 8px;
    stroke: currentColor;
}

/* Modal Styles */
.post-alert-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(1, 28, 135, 0.4);
    backdrop-filter: blur(4px);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.post-alert-modal-content {
    background: var(--pa-bg-white);
    border-radius: 16px;
    padding: 32px;
    width: 90%;
    max-width: 480px;
    position: relative;
    box-shadow: var(--pa-shadow-lg);
}

.post-alert-modal-title {
    color: var(--pa-text-dark);
    font-size: 24px;
    font-weight: 600;
    margin: 0 0 24px 0;
}

.post-alert-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    background: var(--pa-bg-light);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    color: var(--pa-text-muted);
}

.post-alert-close:hover {
    background: var(--pa-border-light);
    color: var(--pa-text-dark);
}

.post-alert-close svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
}

/* Form Styles */
.post-alert-form .form-group {
    margin-bottom: 24px;
}

.post-alert-form label {
    display: block;
    color: var(--pa-text-dark);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.post-alert-form input,
.post-alert-form select {
    width: 100%;
    height: 42px;
    padding: 8px 16px;
    border: 1px solid var(--pa-border-light);
    border-radius: 8px;
    background: var(--pa-bg-white);
    color: var(--pa-text-dark);
    font-size: 14px;
    transition: all 0.2s ease;
    box-shadow: var(--pa-shadow-input);
}

.post-alert-form input:focus,
.post-alert-form select:focus {
    border-color: var(--pa-blue);
    box-shadow: 0 0 0 3px rgba(89, 113, 212, 0.12);
    outline: none;
}
.post-alert-form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}
.post-alert-form-actions .post-alert-submit {
    background: var(--pa-gradient-primary);
    color: var(--pa-bg-white) !important;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    margin-top: 8px;
    display: block;
    flex: 1;
}
.post-alert-form-actions .post-alert-submit.post-alert-unsubscribe {
    background: #fff;
    color: #dc2626 !important;
    border: 1px solid rgba(220, 38, 38, 0.2);
}
.post-alert-form-actions .post-alert-submit.post-alert-unsubscribe:hover {
    background: #fef2f2;
    transform: none;
}
.post-alert-form-actions .post-alert-submit:hover {
    box-shadow: var(--pa-shadow-button);
    transform: translateY(-1px);
}

/* Subscriptions Dashboard Styles */
.post-alert-subscriptions {
    background: var(--pa-bg-white);
    border-radius: 16px;
    box-shadow: var(--pa-shadow-lg);
    padding: 32px;
    margin: 32px 0;
}

.post-alert-subscriptions-header {
    margin-bottom: 24px;
}

.post-alert-subscriptions-header h2 {
    color: var(--pa-text-dark);
    font-size: 24px;
    font-weight: 600;
    margin: 0;
}

/* Table Styles */
.post-alert-table-container {
    background: var(--pa-bg-white);
    border-radius: 12px;
    box-shadow: var(--pa-shadow-md);
    overflow: hidden;
    padding: 1px;
    border: 1px solid var(--pa-border-light);
}

.post-alert-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    background: var(--pa-bg-white);
    margin-block-end: 0;
}

.post-alert-table thead th {
    background: var(--pa-bg-light);
    padding: 14px 16px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--pa-text-dark);
    border: none;
    border-bottom: 1px solid var(--pa-border-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-block-start: none !important;
}

.post-alert-table thead th:first-child {
    padding-left: 24px;
}

.post-alert-table thead th:last-child {
    padding-right: 24px;
}

.post-alert-table tbody tr {
    background: var(--pa-bg-white);
    transition: background-color 0.2s ease;
}

.post-alert-table tbody tr:hover {
    background: var(--pa-bg-light);
}

.post-alert-table tbody td {
    padding: 16px;
    border: none;
    border-bottom: 1px solid var(--pa-border-light);
    font-size: 14px;
    color: var(--pa-text-dark);
    background: transparent !important;
    vertical-align: middle;
}

.post-alert-table tbody td:first-child {
    padding-left: 24px;
}

.post-alert-table tbody td:last-child {
    padding-right: 24px;
}

.post-alert-table tbody tr:last-child td {
    border-bottom: none;
}

/* Table Inputs and Selects */
.post-alert-table input[type="email"],
.post-alert-table select {
    width: 100%;
    max-width: 250px;
    padding: 8px 12px;
    border: 1px solid var(--pa-border-light);
    border-radius: 6px;
    font-size: 14px;
    color: var(--pa-text-dark);
    background: var(--pa-bg-white);
    transition: all 0.2s ease;
    height: 36px;
    line-height: 20px;
}

.post-alert-table input[type="email"]:focus,
.post-alert-table select:focus {
    border-color: var(--pa-blue);
    box-shadow: 0 0 0 3px rgba(89, 113, 212, 0.12);
    outline: none;
}

/* Table Action Buttons */
.post-alert-actions {
    white-space: nowrap;
}

.post-alert-table .post-alert-update,
.post-alert-table .post-alert-delete {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    height: 36px;
    line-height: 20px;
}

.post-alert-table .post-alert-update {
    background: var(--pa-gradient-secondary);
    color: var(--pa-text-dark);
    border: none;
    margin-right: 12px;
}

.post-alert-table .post-alert-delete {
    background: #fff;
    color: #dc2626;
    border: 1px solid rgba(220, 38, 38, 0.2);
}

.post-alert-table .post-alert-delete:hover {
    background: #fef2f2;
}

/* Empty State */
.post-alert-empty-state {
    text-align: center;
    padding: 48px 24px;
    color: var(--pa-text-muted);
    background: var(--pa-bg-light);
    border-radius: 12px;
    margin: 24px 0;
}

.post-alert-empty-state svg {
    margin-bottom: 16px;
    color: var(--pa-text-muted);
}

.post-alert-empty-state p {
    margin: 0;
    font-size: 15px;
}
/* Notification Styles */
.post-alert-notification {
    position: fixed;
    top: 32px;
    right: 20px;
    z-index: 99999;
    transform: translateX(120%);
    transition: transform 0.3s ease-in-out;
}

.post-alert-notification.show {
    transform: translateX(0);
}

.post-alert-notification-content {
    background: var(--pa-bg-white);
    border-radius: 12px;
    box-shadow: var(--pa-shadow-lg);
    padding: 16px 20px;
    margin: 8px 0;
    display: flex;
    align-items: center;
    min-width: 300px;
    max-width: 400px;
}

.post-alert-notification-success .post-alert-notification-content {
    background: var(--pa-gradient-primary);
    color: var(--pa-bg-white);
}

.post-alert-notification-error .post-alert-notification-content {
    background: #fef2f2;
    border: 1px solid rgba(220, 38, 38, 0.2);
    color: #dc2626;
}

.post-alert-notification-message {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
}

@media screen and (max-width: 782px) {
    .post-alert-notification {
        top: 46px;
        right: 10px;
        left: 10px;
    }

    .post-alert-notification-content {
        margin: 5px 0;
        min-width: 0;
    }
}
