/* ============================================
   COMPONENTS
   Forms, Buttons, Inputs, Status Messages
   ============================================ */

/* Form Groups */
.form-group { 
    margin-bottom: 18px; 
}

.form-group:last-child { 
    margin-bottom: 0; 
}

/* Labels */
label { 
    display: block; 
    font-size: 13px; 
    font-weight: 600; 
    margin-bottom: 8px; 
    color: var(--text-primary);
}

/* Text Inputs */
input[type="text"], 
input[type="email"] { 
    width: 100%; 
    padding: 14px 16px; 
    border: 1px solid var(--border); 
    border-radius: var(--radius-lg); 
    font-size: 15px; 
    font-family: inherit; 
    transition: all var(--transition-normal); 
    background: var(--background-subtle);
}

input:focus { 
    outline: none; 
    border-color: var(--accent); 
    box-shadow: 0 0 0 4px var(--accent-light);
    background: white;
}

input::placeholder { 
    color: #94a3b8; 
}

/* Checkbox Group */
.checkbox-group { 
    display: flex; 
    align-items: flex-start; 
    gap: 12px; 
}

.checkbox-group input[type="checkbox"] { 
    width: 20px; 
    height: 20px; 
    margin-top: 2px; 
    accent-color: var(--accent);
    cursor: pointer;
}

.checkbox-group label { 
    font-size: 13px; 
    font-weight: 400; 
    color: var(--text-secondary); 
    margin-bottom: 0; 
    line-height: 1.6;
    cursor: pointer;
}

/* Primary Button */
.btn-primary { 
    width: 100%; 
    padding: 16px 24px; 
    background: var(--accent); 
    color: white; 
    border: none; 
    border-radius: var(--radius-lg); 
    font-size: 15px; 
    font-weight: 600; 
    cursor: pointer; 
    transition: all var(--transition-normal); 
    font-family: inherit; 
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary:hover:not(:disabled) { 
    background: var(--accent-hover); 
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(56, 210, 0, 0.3);
}

.btn-primary:disabled { 
    opacity: 0.5; 
    cursor: not-allowed; 
}

/* Secondary Button */
.btn-secondary { 
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    border: 1px solid var(--border); 
    background: white; 
    border-radius: var(--radius-md); 
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition-normal);
    font-family: inherit;
}

.btn-secondary:hover { 
    background: var(--border-light);
    border-color: var(--text-secondary);
    color: var(--text-primary);
}

/* CMD Button */
.btn-cmd {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 20px;
    background: var(--cmd-blue);
    color: white;
    border: none;
    border-radius: var(--radius-lg);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
    font-family: inherit;
}

.btn-cmd:hover {
    background: var(--cmd-blue-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}

.btn-cmd svg {
    flex-shrink: 0;
}

/* Print Button */
.btn-print {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 20px;
    background: var(--text-secondary);
    color: white;
    border: none;
    border-radius: var(--radius-lg);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
    font-family: inherit;
}

.btn-print:hover {
    background: var(--text-primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(100, 116, 139, 0.3);
}

/* Status Messages */
.status-message { 
    padding: 14px 18px; 
    border-radius: var(--radius-lg); 
    font-size: 14px; 
    margin-top: 16px; 
    display: none;
}

.status-message.success { 
    background: linear-gradient(135deg, var(--success-light) 0%, var(--success-border) 100%); 
    color: #047857;
    border: 1px solid #a7f3d0;
    display: block; 
}

.status-message.error { 
    background: linear-gradient(135deg, var(--error-light) 0%, #fecaca 100%); 
    color: #b91c1c;
    border: 1px solid #fca5a5;
    display: block; 
}

/* Loading Spinner */
.loading { 
    display: inline-block; 
    width: 18px; 
    height: 18px; 
    border: 2px solid rgba(255,255,255,0.3); 
    border-radius: 50%; 
    border-top-color: white; 
    animation: spin 0.8s ease-in-out infinite; 
}

@keyframes spin { 
    to { transform: rotate(360deg); } 
}

/* Toast Notification (new) */
.toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: 14px 24px;
    background: var(--text-primary);
    color: white;
    border-radius: var(--radius-lg);
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    z-index: var(--z-toast);
    opacity: 0;
    transition: all var(--transition-slow);
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast.success {
    background: var(--success);
}

.toast.error {
    background: var(--error);
}
