/* ============================================================
   EAC Base Manager V2 — Front-end Styles
   ============================================================ */

.eac-bm-wrapper {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, sans-serif;
    color: #1e293b;
}

/* Header */
.eac-bm-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e2e8f0;
}
.eac-bm-header h2 {
    margin: 0 0 5px 0;
    font-size: 24px;
    font-weight: 700;
    color: #0f172a;
}
.eac-bm-subtitle {
    margin: 0;
    font-size: 14px;
    color: #64748b;
}
.eac-bm-badge-admin {
    display: inline-block;
    background: #7c3aed;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    margin-left: 8px;
    vertical-align: middle;
}

/* Notices */
.eac-bm-notice {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 1.5;
}
.eac-bm-success { background: #f0fdf4; border: 1px solid #86efac; color: #166534; }
.eac-bm-error { background: #fef2f2; border: 1px solid #fca5a5; color: #991b1b; }
.eac-bm-info { background: #f0f9ff; border: 1px solid #93c5fd; color: #1e40af; }

/* Base sections */
.eac-bm-base-section {
    margin-bottom: 30px;
}
.eac-bm-base-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 15px 0;
    padding: 12px 16px;
    background: #f1f5f9;
    border-radius: 10px;
    color: #0f172a;
}
.eac-bm-base-dot {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #3b82f6;
    flex-shrink: 0;
}
.eac-bm-event-count {
    margin-left: auto;
    font-size: 13px;
    font-weight: 400;
    color: #64748b;
}

/* Event cards */
.eac-bm-events-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-left: 15px;
}
.eac-bm-event-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 18px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    transition: box-shadow 0.2s, border-color 0.2s;
}
.eac-bm-event-card:hover {
    border-color: #cbd5e1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}
.eac-bm-event-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}
.eac-bm-event-title {
    font-size: 15px;
    font-weight: 600;
    color: #0f172a;
}
.eac-bm-event-dates, .eac-bm-event-time {
    font-size: 13px;
    color: #475569;
}
.eac-bm-event-status {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 20px;
    width: fit-content;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.eac-bm-status-publish { background: #dcfce7; color: #166534; }
.eac-bm-status-draft { background: #fef3c7; color: #92400e; }

/* Action buttons */
.eac-bm-event-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    margin-left: 12px;
}

/* Buttons */
.eac-bm-btn {
    display: inline-block;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 7px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.15s;
    line-height: 1.4;
    white-space: nowrap;
}
.eac-bm-btn-duplicate {
    background: #1e40af;
    color: #fff;
}
.eac-bm-btn-duplicate:hover {
    background: #1e3a8a;
    box-shadow: 0 2px 6px rgba(30, 64, 175, 0.3);
}
.eac-bm-btn-edit {
    background: #d97706;
    color: #fff;
}
.eac-bm-btn-edit:hover {
    background: #b45309;
    box-shadow: 0 2px 6px rgba(217, 119, 6, 0.3);
}
.eac-bm-btn-delete {
    background: #dc2626;
    color: #fff;
}
.eac-bm-btn-delete:hover {
    background: #b91c1c;
    box-shadow: 0 2px 6px rgba(220, 38, 38, 0.3);
}
.eac-bm-btn-primary {
    background: #059669;
    color: #fff;
    padding: 12px 24px;
    font-size: 15px;
}
.eac-bm-btn-primary:hover {
    background: #047857;
}
.eac-bm-btn-danger {
    background: #dc2626;
    color: #fff;
    padding: 12px 24px;
    font-size: 15px;
}
.eac-bm-btn-danger:hover {
    background: #991b1b;
}
.eac-bm-btn-cancel {
    background: #f1f5f9;
    color: #475569;
    padding: 12px 20px;
    font-size: 15px;
}
.eac-bm-btn-cancel:hover {
    background: #e2e8f0;
}

/* ============================================================
   MODAL
   ============================================================ */
.eac-bm-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.eac-bm-modal-content {
    background: #fff;
    border-radius: 16px;
    padding: 30px;
    width: 100%;
    max-width: 520px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: eac-bm-slide-up 0.25s ease;
}
@keyframes eac-bm-slide-up {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
.eac-bm-modal-content h3 {
    margin: 0 0 20px 0;
    font-size: 20px;
    font-weight: 700;
    color: #0f172a;
}
.eac-bm-modal-wide {
    max-width: 620px;
}

/* Form elements */
.eac-bm-form-info {
    margin-bottom: 20px;
    padding: 12px 15px;
    background: #e0e7ff;
    border-radius: 8px;
    color: #3730a3;
}
.eac-bm-form-info p { margin: 0; font-size: 14px; }

.eac-bm-form-warning {
    margin-bottom: 20px;
    padding: 15px;
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 8px;
    text-align: center;
}
.eac-bm-form-warning p { margin: 5px 0; }
.eac-bm-text-muted { color: #94a3b8; font-size: 13px; }

.eac-bm-form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}
.eac-bm-form-field {
    flex: 1;
    display: flex;
    flex-direction: column;
}
.eac-bm-form-field label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 5px;
}
.eac-bm-form-field input[type="date"],
.eac-bm-form-field input[type="time"] {
    padding: 10px 12px;
    font-size: 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    color: #1e293b;
    transition: border-color 0.2s;
}
.eac-bm-form-field input[type="text"],
.eac-bm-form-field input[type="url"],
.eac-bm-form-field textarea {
    padding: 10px 12px;
    font-size: 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    color: #1e293b;
    transition: border-color 0.2s;
    width: 100%;
    box-sizing: border-box;
    font-family: inherit;
}
.eac-bm-form-field textarea {
    resize: vertical;
    min-height: 80px;
}
.eac-bm-form-field input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}
.eac-bm-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}
.eac-bm-form-section-title {
    font-size: 14px;
    font-weight: 600;
    color: #475569;
    margin: 18px 0 10px 0;
    padding-bottom: 6px;
    border-bottom: 1px solid #e2e8f0;
}
.eac-bm-form-section-title:first-of-type {
    margin-top: 0;
}
.eac-bm-form-field-full {
    flex: 1 1 100%;
}
.eac-bm-event-cost {
    font-size: 13px;
    color: #059669;
    font-weight: 500;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 700px) {
    .eac-bm-wrapper { padding: 12px; }
    .eac-bm-event-card {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .eac-bm-event-actions {
        margin-left: 0;
        flex-wrap: wrap;
    }
    .eac-bm-btn {
        flex: 1;
        text-align: center;
        min-width: 0;
    }
    .eac-bm-form-row { flex-direction: column; gap: 10px; }
    .eac-bm-form-actions { flex-direction: column; }
    .eac-bm-modal-content { padding: 20px; }
    .eac-bm-events-list { padding-left: 0; }
}

/* ============================================================
   LOGIN FORM
   ============================================================ */
.eac-bm-login-container {
    max-width: 400px;
    margin: 40px auto;
    padding: 35px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    text-align: center;
}
.eac-bm-login-logo {
    font-size: 48px;
    margin-bottom: 10px;
    line-height: 1;
}
.eac-bm-login-container h2 {
    margin: 0 0 6px 0;
    font-size: 22px;
    font-weight: 700;
    color: #0f172a;
}
.eac-bm-login-subtitle {
    margin: 0 0 25px 0;
    font-size: 14px;
    color: #64748b;
}
.eac-bm-login-form {
    text-align: left;
}
.eac-bm-login-form .eac-bm-form-field {
    margin-bottom: 16px;
}
.eac-bm-login-form input[type="text"],
.eac-bm-login-form input[type="password"] {
    width: 100%;
    padding: 11px 14px;
    font-size: 15px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    color: #1e293b;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.eac-bm-login-form input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}
.eac-bm-btn-full {
    width: 100%;
    text-align: center;
    padding: 13px 20px;
    font-size: 16px;
    margin-top: 4px;
}
.eac-bm-login-footer {
    margin-top: 18px;
    font-size: 13px;
}
.eac-bm-login-footer a {
    color: #6366f1;
    text-decoration: none;
}
.eac-bm-login-footer a:hover {
    text-decoration: underline;
}

/* Header with logout */
.eac-bm-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.eac-bm-header-top h2 {
    margin: 0;
}
.eac-bm-btn-logout {
    background: #f1f5f9;
    color: #64748b;
    font-size: 13px;
    padding: 7px 16px;
    border-radius: 7px;
    text-decoration: none;
}
.eac-bm-btn-logout:hover {
    background: #e2e8f0;
    color: #475569;
}

@media (max-width: 480px) {
    .eac-bm-login-container {
        margin: 20px auto;
        padding: 25px 20px;
    }
}
