/* Registration Form Styles */
.csc-registration-form {
    max-width: 400px;
    margin: 20px auto;
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: #f9f9f9;
}

.csc-registration-form h3 {
    text-align: center;
    margin-bottom: 20px;
}

.csc-registration-form p {
    margin-bottom: 15px;
}

.csc-registration-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.csc-registration-form input[type="text"],
.csc-registration-form input[type="email"],
.csc-registration-form input[type="password"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 3px;
}

.csc-registration-form button {
    width: 100%;
    padding: 12px;
    background: #0073aa;
    color: white;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 16px;
}

.csc-registration-form button:hover {
    background: #005a87;
}

/* Dashboard Styles */
.csc-dashboard {
    max-width: 1000px;
    margin: 20px auto;
    padding: 20px;
}

.csc-dashboard h2 {
    margin-bottom: 10px;
}

/* User List Styles */
.csc-user-list {
    margin: 20px 0;
}

.csc-users {
    list-style: none;
    padding: 0;
}

.csc-user-item {
    padding: 12px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.csc-user-item:hover {
    background: #f0f0f0;
}

.user-status {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 10px;
}

.user-status.online {
    background: #4caf50;
}

.user-status.offline {
    background: #ccc;
}

/* Chat Box Styles */
.csc-chat-box {
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-top: 20px;
}

.csc-chat-header {
    padding: 15px;
    background: #0073aa;
    color: white;
    border-radius: 5px 5px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.csc-chat-header h4 {
    margin: 0;
}

.csc-online-status {
    padding: 5px 15px;
    background: rgba(255,255,255,0.2);
    border-radius: 15px;
    font-size: 12px;
}

.csc-chat-messages {
    height: 400px;
    overflow-y: auto;
    padding: 15px;
    background: #fff;
}

.csc-message {
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 5px;
    max-width: 70%;
}

.csc-message.own-message {
    background: #dcf8c6;
    margin-left: auto;
    text-align: right;
}

.csc-message.other-message {
    background: #f1f1f1;
}

.message-time {
    display: block;
    font-size: 11px;
    color: #666;
    margin-top: 5px;
}

.csc-chat-input {
    display: flex;
    padding: 15px;
    border-top: 1px solid #ddd;
    background: #f9f9f9;
}

.csc-chat-input input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 3px;
    margin-right: 10px;
}

.csc-chat-input button {
    padding: 10px 20px;
    background: #0073aa;
    color: white;
    border: none;
    border-radius: 3px;
    cursor: pointer;
}

.csc-chat-input button:hover {
    background: #005a87;
}


/* Additional Template Styles */

/* Dashboard Page Layout */
.csc-dashboard-page {
    background: #f5f7fa;
    margin: 0;
    padding: 0;
}

.csc-dashboard-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styles */
.csc-sidebar {
    width: 280px;
    background: #2c3e50;
    color: white;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.csc-sidebar-header {
    padding: 20px;
    background: #1a252f;
    text-align: center;
}

.csc-sidebar-header h3 {
    margin: 0;
    color: white;
}

.csc-user-profile {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.csc-avatar {
    margin-bottom: 15px;
}

.csc-avatar img {
    border-radius: 50%;
    border: 3px solid #3498db;
}

.csc-user-profile h4 {
    margin: 10px 0 5px;
    color: white;
}

.user-role {
    color: #3498db;
    font-size: 14px;
}

.csc-sidebar-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.csc-sidebar-nav li a {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: #bdc3c7;
    text-decoration: none;
    transition: all 0.3s;
}

.csc-sidebar-nav li a:hover,
.csc-sidebar-nav li a.active {
    background: #34495e;
    color: white;
    border-left: 4px solid #3498db;
}

.csc-sidebar-nav .dashicons {
    margin-right: 12px;
    font-size: 20px;
}

/* Main Content Area */
.csc-main-content {
    flex: 1;
    margin-left: 280px;
    padding: 30px;
}

.csc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.csc-header h2 {
    margin: 0;
    color: #2c3e50;
}

.current-time {
    color: #7f8c8d;
    font-size: 14px;
}

/* Stats Grid */
.csc-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
}

.stat-icon .dashicons {
    font-size: 30px;
    color: white;
}

.stat-info h4 {
    margin: 0 0 5px;
    font-size: 28px;
    color: #2c3e50;
}

.stat-info p {
    margin: 0;
    color: #7f8c8d;
    font-size: 14px;
}

/* Chat Section */
.csc-chat-section {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    overflow: hidden;
    height: 600px;
}

.csc-users-panel {
    border-right: 1px solid #ecf0f1;
    display: flex;
    flex-direction: column;
}

.panel-header {
    padding: 20px;
    border-bottom: 1px solid #ecf0f1;
}

.panel-header h3 {
    margin: 0 0 15px;
    color: #2c3e50;
}

.search-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.csc-user-list {
    flex: 1;
    overflow-y: auto;
}

.csc-users {
    list-style: none;
    padding: 0;
    margin: 0;
}

.csc-user-item {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    cursor: pointer;
    transition: background 0.3s;
    position: relative;
}

.csc-user-item:hover {
    background: #f8f9fa;
}

.csc-user-item.active {
    background: #e3f2fd;
}

.user-avatar {
    margin-right: 15px;
}

.user-avatar img {
    border-radius: 50%;
}

.user-info {
    flex: 1;
}

.user-info h4 {
    margin: 0 0 5px;
    font-size: 15px;
    color: #2c3e50;
}

.user-status {
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 10px;
    display: inline-block;
}

.user-status.online {
    background: #d4edda;
    color: #155724;
}

.user-status.offline {
    background: #f8d7da;
    color: #721c24;
}

.unread-count {
    background: #e74c3c;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

/* Chat Panel */
.csc-chat-panel {
    display: flex;
    flex-direction: column;
    position: relative;
}

.csc-no-chat-selected {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #95a5a6;
}

.csc-no-chat-selected .dashicons {
    font-size: 80px;
    margin-bottom: 20px;
}

.csc-chat-box {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.chat-user-info {
    display: flex;
    align-items: center;
}

#chat-user-avatar {
    margin-right: 15px;
}

#chat-user-avatar img {
    border-radius: 50%;
}

.close-chat {
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    padding: 5px;
}

.close-chat:hover {
    opacity: 0.8;
}

/* Registration Wrapper */
.csc-registration-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.csc-registration-container {
    background: white;
    border-radius: 10px;
    padding: 40px;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.csc-registration-header {
    text-align: center;
    margin-bottom: 30px;
}

.csc-registration-header h2 {
    margin: 0 0 10px;
    color: #2c3e50;
}

.csc-form .form-group {
    margin-bottom: 20px;
}

.csc-form label {
    display: block;
    margin-bottom: 8px;
    color: #2c3e50;
    font-weight: 500;
}

.required {
    color: #e74c3c;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
}

.btn-submit {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s;
}

.btn-submit:hover {
    transform: translateY(-2px);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.csc-form-footer {
    margin-top: 30px;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #ecf0f1;
}

.csc-form-footer p {
    margin: 10px 0;
    color: #7f8c8d;
}

.csc-form-footer a {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
}

.csc-form-footer a:hover {
    text-decoration: underline;
}

.success-message,
.error-message {
    padding: 15px;
    border-radius: 5px;
    margin-top: 20px;
    text-align: center;
}

.success-message {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.no-users {
    padding: 40px 20px;
    text-align: center;
    color: #95a5a6;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .csc-sidebar {
        width: 250px;
    }
    
    .csc-main-content {
        margin-left: 250px;
    }
    
    .csc-chat-section {
        grid-template-columns: 300px 1fr;
    }
}

@media (max-width: 768px) {
    .csc-sidebar {
        width: 100%;
        position: relative;
        height: auto;
    }
    
    .csc-main-content {
        margin-left: 0;
    }
    
    .csc-chat-section {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .csc-users-panel {
        border-right: none;
        border-bottom: 1px solid #ecf0f1;
    }
}
