/* RC Analyzer v2.0 - Design System */

:root {
    /* Brand Colors */
    --brand-primary: #003366;   /* Azul Escuro */
    --brand-secondary: #00BFFF; /* Azul Claro Vibrante */
    --brand-accent: #FF8C00;    /* Laranja Ação */

    /* Neutral & Backgrounds */
    --bg-body: #F5F7FA;
    --bg-surface: #FFFFFF;
    
    /* Text Colors */
    --text-heading: #002244;
    --text-body: #5A6A85;
    --text-muted: #A0AEC0;
    
    /* Borders & Shadows */
    --border-color: #E2E8F0;
    --shadow-card: 0 2px 12px rgba(0, 51, 102, 0.08);
    --shadow-focus: 0 0 0 3px rgba(0, 191, 255, 0.3);

    /* Semantic Alerts */
    --alert-success: #FF8C00; /* Laranja para sucesso (logo check) */
    --alert-error: #C53030;
    --alert-warning: #DD6B20;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-body);
    color: var(--text-body);
    font-weight: 400;
    line-height: 1.6;
    display: flex;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--text-heading);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Layout */
.app-container {
    display: flex;
    width: 100%;
}

.main-content {
    flex: 1;
    padding: 2rem;
    margin-left: 260px; /* Width of sidebar */
}

/* Sidebar */
.sidebar {
    width: 260px;
    background-color: var(--brand-primary);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    padding: 2rem 1rem;
    display: flex;
    flex-direction: column;
    z-index: 100;
}

.sidebar h2 {
    color: var(--brand-accent);
    font-weight: 700;
    font-size: 1.5rem;
    margin-bottom: 2rem;
    text-align: center;
    letter-spacing: 1px;
}

.sidebar a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0.8rem 1rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease-in-out;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.sidebar a i {
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
    color: var(--brand-secondary);
    transition: all 0.3s ease-in-out;
}

.sidebar a:hover, .sidebar a.active {
    background-color: rgba(0, 191, 255, 0.1);
    color: #fff;
}

.sidebar a:hover i, .sidebar a.active i {
    color: var(--brand-accent);
}

.sidebar-spacer {
    flex-grow: 1;
}

/* Cards */
.card {
    background: var(--bg-surface);
    border-radius: 12px;
    box-shadow: var(--shadow-card);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: none;
}

.card-title {
    color: var(--text-heading);
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-title i {
    color: var(--brand-secondary);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    text-decoration: none;
    border: none;
    font-size: 0.95rem;
}

.btn-primary {
    background-color: var(--brand-accent);
    color: #fff;
}

.btn-primary:hover {
    background-color: #E07B00; /* Darker Orange */
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--brand-primary);
    border: 1px solid var(--brand-primary);
}

.btn-secondary:hover {
    background-color: var(--brand-primary);
    color: #fff;
}

.btn-ghost {
    background-color: transparent;
    color: var(--brand-secondary);
}

.btn-ghost:hover {
    background-color: rgba(0, 191, 255, 0.1);
}

/* Forms */
.form-group {
    margin-bottom: 1.2rem;
}

label {
    display: block;
    color: var(--text-heading);
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--bg-surface);
    color: var(--text-body);
    font-family: inherit;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--brand-secondary);
    box-shadow: var(--shadow-focus);
}

input::placeholder {
    color: var(--text-muted);
}

/* Login Split Screen Layout */
.login-wrapper {
    display: flex;
    height: 100vh;
    width: 100%;
}

.login-brand {
    flex: 1.2;
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-secondary) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    position: relative;
    overflow: hidden;
}

/* Subtle wave overlay effect */
.login-brand::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: radial-gradient(circle at 2px 2px, rgba(255,255,255,0.1) 1px, transparent 0);
    background-size: 32px 32px;
}

.login-brand h1 {
    color: white;
    font-size: 3rem;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.login-brand p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.2rem;
    position: relative;
    z-index: 1;
}

.login-form-area {
    flex: 1;
    background-color: var(--bg-surface);
    display: flex;
    justify-content: center;
    align-items: center;
}

.login-box {
    width: 100%;
    max-width: 400px;
    padding: 2rem;
}

.login-box h2 {
    color: var(--text-heading);
    margin-bottom: 2rem;
    font-size: 1.8rem;
}

/* Alerts / Badges */
.badge {
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-success { background-color: rgba(255, 140, 0, 0.1); color: var(--alert-success); border: 1px solid rgba(255, 140, 0, 0.2); }
.badge-error { background-color: rgba(197, 48, 48, 0.1); color: var(--alert-error); border: 1px solid rgba(197, 48, 48, 0.2); }
.badge-warning { background-color: rgba(221, 107, 32, 0.1); color: var(--alert-warning); border: 1px solid rgba(221, 107, 32, 0.2); }
.badge-info { background-color: rgba(0, 191, 255, 0.1); color: var(--brand-secondary); border: 1px solid rgba(0, 191, 255, 0.2); }

/* Tables */
.table-container {
    width: 100%;
    overflow-x: auto;
}

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

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

th {
    color: var(--text-heading);
    font-weight: 600;
    background-color: rgba(245, 247, 250, 0.5);
}

tr:hover td {
    background-color: rgba(245, 247, 250, 0.8);
}
