/* Hi Team Agenda Manager - Global Styles */

:root {
    --hi-orange: #F26522;
    --hi-yellow: #F2B840;
    --hi-blue: #1C75BC;
    --hi-green: #6CBE45;
    --hi-red: #C32034;
    --hi-light-blue: #1B9ED1;
    --hi-gray: #7A797A;
    --hi-light-gray: #BBBCBB;
    --input-bg: #FFF8F0;
    --calc-bg: #F0F7FF;
    --break-bg: #E8F4FC;
    --meal-bg: #FFF5E6;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: #f5f5f5;
    color: #333;
    line-height: 1.5;
}

a {
    color: var(--hi-blue);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    background: var(--hi-orange);
    color: white;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

header nav {
    display: flex;
    gap: 20px;
    align-items: center;
}

header nav a {
    color: white;
    opacity: 0.9;
    font-weight: 500;
}

header nav a:hover {
    opacity: 1;
    text-decoration: none;
}

header nav a.active {
    border-bottom: 2px solid white;
    padding-bottom: 2px;
}

/* Buttons */
button, .btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

button:hover, .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.btn-primary {
    background: var(--hi-blue);
    color: white;
}

.btn-secondary {
    background: var(--hi-light-gray);
    color: white;
}

.btn-success {
    background: var(--hi-green);
    color: white;
}

.btn-danger {
    background: var(--hi-red);
    color: white;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--hi-blue);
    color: var(--hi-blue);
}

.btn-small {
    padding: 6px 12px;
    font-size: 0.8rem;
}

/* Cards */
.card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 1px 5px rgba(0,0,0,0.1);
    margin-bottom: 15px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--hi-blue);
}

.card-meta {
    color: var(--hi-gray);
    font-size: 0.9rem;
}

/* Status Badge */
.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-draft {
    background: #f0f0f0;
    color: #666;
}

.status-confirmed {
    background: #E3F2FD;
    color: #1565C0;
}

.status-completed {
    background: #E8F5E9;
    color: #2E7D32;
}

.status-archived {
    background: #ECEFF1;
    color: #546E7A;
}

.status-cancelled {
    background: #FFEBEE;
    color: #C62828;
}

/* Forms */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--hi-gray);
    font-size: 0.85rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--hi-blue);
    box-shadow: 0 0 0 3px rgba(28, 117, 188, 0.1);
}

/* Modal */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

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

.modal {
    background: white;
    border-radius: 12px;
    padding: 25px;
    width: 500px;
    max-width: 90vw;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.modal h2 {
    color: var(--hi-orange);
    margin-bottom: 20px;
}

.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.page-header h2 {
    color: var(--hi-gray);
    font-size: 1.3rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--hi-gray);
}

.empty-state h3 {
    margin-bottom: 10px;
    color: var(--hi-gray);
}

/* Grid */
.grid {
    display: grid;
    gap: 15px;
}

.grid-2 {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

/* Loader */
.loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--hi-orange);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Save indicator */
.save-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
}

.save-indicator.saving {
    background: #FFF3CD;
    color: #856404;
}

.save-indicator.saved {
    background: #D4EDDA;
    color: #155724;
}

.save-indicator.error {
    background: #F8D7DA;
    color: #721C24;
}

/* Login Page */
.login-container {
    max-width: 400px;
    margin: 100px auto;
    padding: 20px;
}

.login-card {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    text-align: center;
}

.login-card h1 {
    color: var(--hi-orange);
    margin-bottom: 10px;
}

.login-card p {
    color: var(--hi-gray);
    margin-bottom: 30px;
}

.login-card .form-group {
    text-align: left;
}

.login-card button {
    width: 100%;
    margin-top: 10px;
}

.login-error {
    background: #F8D7DA;
    color: #721C24;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 20px;
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 15px;
    }

    header nav {
        width: 100%;
        justify-content: center;
    }

    .page-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
}
