@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Merriweather:wght@300;400;700&display=swap');

:root {
    /* Color Palette - GitHub Dark */
    --primary-color: #238636; /* GitHub Success Green for primary actions */
    --primary-hover: #2ea043;
    --secondary-color: #8b949e; 
    --background-color: #0d1117; /* GitHub Dark BG */
    --surface-color: #161b22; /* GitHub Dark Surface */
    --text-primary: #c9d1d9; /* GitHub Text */
    --text-secondary: #8b949e; /* Muted Text */
    --border-color: #30363d;
    --link-color: #58a6ff;
    --link-hover: #79c0ff;
    
    /* Semantic Colors */
    --success: #238636; 
    --warning: #d29922;
    --danger: #da3633; 
    
    /* Typography */
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
    --font-serif: var(--font-sans);
    
    /* Layout Variables */
    --sidebar-width: 250px;
    --header-height: 60px;
    
    /* Effects */
    --shadow-sm: none;
    --shadow-md: none;
    --transition: all 0.15s ease-in-out;
    --border-radius: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 14px; /* GitHub uses 14px base font */
}

body {
    font-family: var(--font-sans);
    background-color: var(--background-color);
    color: var(--text-primary);
    line-height: 1.5;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.25;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--link-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--link-hover);
    text-decoration: underline;
}

button {
    cursor: pointer;
    font-family: var(--font-sans);
    border: none;
    outline: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #ffffff;
    border: 1px solid rgba(240, 246, 252, 0.1);
    padding: 5px 16px;
    border-radius: var(--border-radius);
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: rgba(240, 246, 252, 0.1);
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}

.btn-danger {
    background-color: var(--surface-color);
    color: var(--danger);
    border: 1px solid var(--border-color);
    padding: 5px 16px;
    border-radius: var(--border-radius);
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
}

.btn-danger:hover {
    background-color: var(--danger);
    color: #ffffff;
    border-color: var(--danger);
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}

.btn:disabled, button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* Layout Utilities */
.app-container {
    display: flex;
    min-height: 100vh;
}

.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 1.5rem;
    min-height: 100vh;
}

.card {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Form Styling */
.form-control, .form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--text-primary);
    background-color: var(--surface-color);
    transition: border-color 0.2s ease;
}

.form-control:focus, .form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(35, 134, 54, 0.3);
}

.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper .form-control {
    padding-right: 3.5rem;
}

.password-toggle-btn {
    position: absolute;
    right: 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    font-family: inherit;
}

.password-toggle-btn:hover {
    color: var(--primary-color);
}

/* Profile Modal Styles */
.profile-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.profile-modal-overlay.active {
    display: flex;
}

.profile-modal {
    background: var(--surface-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    width: 400px;
    max-width: 90%;
    box-shadow: var(--shadow);
    position: relative;
}

.profile-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 1.5rem;
}

.profile-modal-close:hover {
    color: var(--text-primary);
}

.profile-modal-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.profile-modal-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
}

.profile-modal-info h3 {
    margin-bottom: 0.25rem;
}

.profile-modal-info p {
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* Table Styling */
.table-container {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background-color: #0d1117;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
}

td {
    font-size: 0.9rem;
}

tbody tr {
    transition: background-color 0.15s ease;
}

tbody tr:hover {
    background-color: rgba(240, 246, 252, 0.03);
}

.profile-detail-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

.profile-detail-row:last-child {
    border-bottom: none;
}

.profile-detail-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.profile-detail-value {
    color: var(--text-primary);
    font-weight: 600;
}

/* Generic Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--surface-color);
    margin: auto;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    width: 80%;
    max-width: 500px;
    box-shadow: var(--shadow);
}
