/* ALS Forms Admin Styles */

.template-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(0, 0, 0, 0.5) !important;
    z-index: 999999 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 20px !important;
    box-sizing: border-box !important;
    inset: 0 !important;
    transform: none !important;
}

.template-modal-content {
    background: #fff !important;
    padding: 32px !important;
    border-radius: 8px !important;
    min-width: 320px !important;
    max-width: 90vw !important;
    max-height: 90vh !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
    position: relative !important;
    overflow: auto !important;
    transform: translateX(0) translateY(0) !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    bottom: auto !important;
    margin: 0 auto !important;
}

#wpwrap .template-modal,
.wp-admin .template-modal,
body.wp-admin .template-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 999999 !important;
    inset: 0 !important;
}

#wpadminbar ~ * .template-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    inset: 0 !important;
}

.template-modal * {
    box-sizing: border-box !important;
}

.als-btn {
    background: #4fc3f7;
    color: #fff !important;
    border: none;
    border-radius: 5px;
    margin-bottom: 10px;
    padding: 6px 18px;
    font-weight: 600;
    font-size: 1em;
    cursor: pointer;
    text-decoration: none;
    margin-right: 6px;
    transition: background 0.2s;
    display: inline-block;
}

.als-btn:hover {
    background: #4fc3f7;
    color: #fff !important;
}

.als-btn.als-btn-danger {
    background: #ff7675;
    color: #fff !important;
}

.als-btn.als-btn-danger:hover {
    background: #ff7675;
    color: #fff !important;
}

/* Table responsive wrapper */
.als-table-responsive {
    overflow-x: auto;
    margin: 1em 0;
}

.als-table-responsive table {
    min-width: 600px;
}

/* Form styles */
.als-form-wrap {
    max-width: 800px;
}

/* Card styles for dashboard */
.als-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.als-card-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
    color: #333;
}

/* Form list styles */
.als-forms-edit-btn {
    background: #2271b1 !important;
    color: #fff !important;
    border: none !important;
    box-shadow: none !important;
}

.als-forms-edit-btn:hover {
    background: #135e96 !important;
    color: #fff !important;
}

.als-forms-delete-btn {
    background: #d63638 !important;
    color: #fff !important;
    border: none !important;
    box-shadow: none !important;
}

.als-forms-delete-btn:hover {
    background: #a00 !important;
    color: #fff !important;
}

#als-forms-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 9998;
}

#als-forms-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    z-index: 9999;
    min-width: 340px;
    max-width: 95vw;
}

.als-forms-modal-content {
    padding: 32px 24px 24px 24px;
    text-align: center;
}

.als-forms-modal-actions {
    margin-top: 24px;
    display: flex;
    justify-content: center;
    gap: 16px;
}

.als-forms-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.als-forms-actions .button {
    min-width: 90px;
    text-align: center;
    margin: 0 !important;
}

@media (max-width: 500px) {
    .als-forms-modal-content {
        padding: 18px 8px 12px 8px;
    }
}

@media (max-width: 600px) {
    .als-forms-actions {
        flex-direction: column;
        gap: 10px;
    }
}

@media (max-width: 800px) {
    .als-forms-created-at {
        display: none !important;
    }
}

/* Dashboard styles */
.als-dashboard-cards {
    display: flex;
    gap: 32px;
    margin-bottom: 32px;
    flex-wrap: wrap;
}

.als-dashboard-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(80,130,255,0.07);
    padding: 32px 36px;
    min-width: 220px;
    flex: 1 1 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.als-dashboard-card .als-icon {
    font-size: 2.5em;
    margin-bottom: 12px;
}

.als-dashboard-card .als-card-title {
    font-size: 1.1em;
    color: #888;
    margin-bottom: 4px;
}

.als-dashboard-card .als-card-value {
    font-size: 2.2em;
    font-weight: bold;
    color: #4fc3f7;
}

.als-dashboard-section {
    margin-bottom: 36px;
}

.als-dashboard-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(80,130,255,0.07);
}

.als-dashboard-table th, .als-dashboard-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    text-align: left;
}

.als-dashboard-table th {
    background: #f7fafd;
    color: #555;
}

.als-dashboard-table tr:last-child td {
    border-bottom: none;
}

.als-dashboard-links {
    margin-top: 24px;
}

.als-dashboard-links a {
    background: #4fc3f7;
    color: #fff !important;
    border-radius: 5px;
    padding: 8px 22px;
    font-weight: 600;
    font-size: 1em;
    text-decoration: none;
    margin-right: 12px;
    transition: background 0.2s;
    display: inline-block;
}

.als-dashboard-links a:hover {
    background: #039be5;
}

/* JSON view styles */
.als-json-view {
    background: #f7f7f7;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 16px;
    max-height: 400px;
    overflow: auto;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    line-height: 1.4;
}
