/**
 * Admin Styles for User Registration Stats Plugin.
 *
 * @package UserRegistrationStats
 * @since 1.0.0
 */

.wrap.user-reg-stats-admin-page {
    margin-top: 20px;
}

/* Styling for general widgets/cards on the page */
.user-reg-stats-admin-page .user-reg-stats-widget {
    background: #fff;
    border: 1px solid #ccd0d4; /* Standard WordPress border color */
    margin-bottom: 20px;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
}

.user-reg-stats-admin-page .user-reg-stats-widget h2 {
    font-size: 14px; /* Standard WordPress h2 in postbox-like containers */
    padding: 8px 12px;
    margin: 0; /* Remove default h2 margins if .user-reg-stats-widget handles padding */
    line-height: 1.4;
    border-bottom: 1px solid #eee; /* Standard WordPress separator */
}

.user-reg-stats-admin-page .user-reg-stats-widget .inside,
.user-reg-stats-admin-page .user-reg-stats-widget .user-reg-stats-widget-content { /* .inside is a common WP class for postbox content */
    padding: 12px;
    line-height: 1.6;
}
.user-reg-stats-admin-page .user-reg-stats-widget .inside p:first-child,
.user-reg-stats-admin-page .user-reg-stats-widget .user-reg-stats-widget-content p:first-child {
    margin-top: 0;
}
.user-reg-stats-admin-page .user-reg-stats-widget .inside p:last-child,
.user-reg-stats-admin-page .user-reg-stats-widget .user-reg-stats-widget-content p:last-child {
    margin-bottom: 0;
}


/* Layout for the top overview/chart widgets */
.user-reg-stats-admin-page #user-reg-stats-dashboard-widgets-wrap {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Responsive grid */
    gap: 20px;
    margin-bottom: 30px; /* Space below the top widgets section */
}

/* Chart container specific style - ensure canvas is responsive within its container */
.user-reg-stats-admin-page .user-reg-stats-widget .chart-container-wrapper { /* A wrapper for the div with inline style */
    padding-top: 10px; /* Add some space if h2 is not part of this inner div */
}
.user-reg-stats-admin-page .user-reg-stats-widget .chart-container-wrapper div[style*="height: 300px"] {
    /* The inline style sets the height, this can ensure width is responsive */
    max-width: 100%;
}


/* General page elements */
.user-reg-stats-admin-page hr {
    margin: 30px 0;
    border: 0;
    border-top: 1px solid #ddd;
}
.user-reg-stats-admin-page h2 { /* General H2 styling for sections */
    font-size: 1.5em; /* Slightly larger for section titles */
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px dotted #e0e0e0;
}
.user-reg-stats-admin-page #user-reg-stats-dashboard-widgets-wrap h2 { /* Keep widget titles smaller */
     font-size: 14px;
     margin-bottom: 0; /* Handled by .user-reg-stats-widget h2 */
     padding-bottom: 0; /* Handled by .user-reg-stats-widget h2 */
     border-bottom: none; /* Handled by .user-reg-stats-widget h2 */
}


/* Styling for form tables used for filtering etc. */
.user-reg-stats-admin-page .form-table {
    margin-top: 10px;
}
.user-reg-stats-admin-page .form-table th {
    width: 200px; /* Consistent width for labels */
    padding-right: 20px;
}

/* WP_List_Table adjustments */
.user-reg-stats-admin-page .wp-list-table {
    margin-top: 15px;
}
.user-reg-stats-admin-page form > h2 + .wp-list-table, /* If WP_List_Table is directly after an H2 in a form */
.user-reg-stats-admin-page h2 + form > .wp-list-table {
    margin-top: 0;
}


/* Buttons */
.user-reg-stats-admin-page .button-danger {
    background: #d63638;
    border-color: #d63638 #c62f2f #c62f2f;
    box-shadow: 0 1px 0 #c62f2f;
    color: #fff;
    text-decoration: none;
    text-shadow: 0 -1px 1px #c62f2f, 1px 0 1px #c62f2f, 0 1px 1px #c62f2f, -1px 0 1px #c62f2f;
}
.user-reg-stats-admin-page .button-danger:hover,
.user-reg-stats-admin-page .button-danger:focus {
    background: #e04345;
    border-color: #d63638;
    color: #fff;
}

/* Ensure admin notices added via JS are styled consistently */
.user-reg-stats-admin-page .notice {
    margin-left: 0;
    margin-right: 0;
    margin-bottom: 15px;
}