/* Sarawagi Diary - Warm Heritage Theme */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans:wght@400;500;600;700&display=swap');

:root {
    /* Primary Colors */
    --primary: #c9942a;
    --primary-hover: #a67a1f;
    --primary-light: #f5e6c8;

    /* Secondary Colors */
    --secondary: #3d6b35;
    --secondary-hover: #2d5025;

    /* Background Colors */
    --bg-page: #faf8f5;
    --bg-card: #ffffff;
    --bg-paper: #fffcf2;

    /* Text Colors */
    --text-primary: #3d2e1f;
    --text-secondary: #5c4a3a;
    --text-muted: #8a7a6a;

    /* Border Colors */
    --border: #e5ddd3;
    --border-dark: #d4c9bc;

    /* Functional Colors */
    --success: #3d6b35;
    --error: #c44536;
    --error-bg: #fdf2f1;
    --warning: #d4a017;
    --warning-bg: #fef9e7;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(61, 46, 31, 0.08);
    --shadow-md: 0 4px 12px rgba(61, 46, 31, 0.1);
    --shadow-lg: 0 8px 24px rgba(61, 46, 31, 0.12);

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 50%;
}

/* Base Styles */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Noto Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: var(--text-primary);
    background-color: var(--bg-page);
}

h1, h2, h3, h4, h5, h6 {
    color: var(--text-primary);
    font-weight: 600;
    margin: 0 0 0.5em;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--primary-hover);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    color: white;
}

.btn-secondary {
    background-color: var(--secondary);
    color: white;
}

.btn-secondary:hover {
    background-color: var(--secondary-hover);
    color: white;
}

.btn-outline {
    background-color: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-outline:hover {
    background-color: var(--bg-paper);
    color: var(--text-primary);
}

.btn-danger {
    background-color: var(--error);
    color: white;
}

.btn-danger:hover {
    background-color: #a83a2e;
    color: white;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 14px;
}

.form-control {
    width: 100%;
    padding: 10px 12px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text-primary);
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.form-control::placeholder {
    color: var(--text-muted);
}

/* Cards */
.card {
    background-color: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 28px;
}

/* Container */
.container {
    background: var(--bg-card);
    padding: 36px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    width: 100%;
    max-width: 400px;
}

.container-lg {
    max-width: 900px;
}

/* Spacing utilities */
.p-1 { padding: 8px; }
.p-2 { padding: 16px; }
.p-3 { padding: 24px; }
.p-4 { padding: 32px; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }
.gap-3 { gap: 24px; }
.gap-4 { gap: 32px; }

/* Navbar */
.navbar {
    background-color: var(--primary);
    color: white;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--shadow-sm);
}

.navbar a {
    color: white;
    font-weight: 500;
}

.navbar a:hover {
    color: var(--primary-light);
}

.navbar-title {
    font-size: 18px;
    font-weight: 600;
}

.navbar-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-avatar {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    border: 2px solid white;
    object-fit: cover;
}

/* Logo */
.logo {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-full);
    border: 3px solid var(--primary);
    object-fit: cover;
}

.logo-lg {
    width: 100px;
    height: 100px;
}

/* Section Headers */
.section-header {
    color: var(--primary);
    font-size: 18px;
    font-weight: 600;
    padding-bottom: 8px;
    margin-bottom: 16px;
    border-bottom: 2px solid var(--primary);
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    background-color: var(--bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.table th {
    background-color: var(--primary);
    color: white;
    font-weight: 600;
    text-align: left;
    padding: 12px 16px;
}

.table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
}

.table tr:last-child td {
    border-bottom: none;
}

.table tr:hover td {
    background-color: var(--bg-paper);
}

/* Tabs */
.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 10px 20px;
    background-color: var(--bg-card);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.tab-btn.active {
    background-color: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Alerts */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius-md);
    margin-bottom: 16px;
}

.alert-error {
    background-color: var(--error-bg);
    color: var(--error);
    border: 1px solid var(--error);
}

.alert-warning {
    background-color: var(--warning-bg);
    color: #8a6d00;
    border: 1px solid var(--warning);
}

.alert-success {
    background-color: #f0f7ef;
    color: var(--success);
    border: 1px solid var(--success);
}

/* Info Grid (for profile pages) */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.info-item label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.info-item span {
    font-size: 15px;
    color: var(--text-primary);
}

/* Utility Classes */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mt-5 { margin-top: 40px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }
.mb-5 { margin-bottom: 40px; }
.py-1 { padding-top: 8px; padding-bottom: 8px; }
.py-2 { padding-top: 16px; padding-bottom: 16px; }
.py-3 { padding-top: 24px; padding-bottom: 24px; }
.px-1 { padding-left: 8px; padding-right: 8px; }
.px-2 { padding-left: 16px; padding-right: 16px; }
.px-3 { padding-left: 24px; padding-right: 24px; }

/* Link styled as button */
.link-btn {
    display: inline-block;
    padding: 8px 16px;
    background-color: var(--text-muted);
    color: white;
    border-radius: var(--radius-md);
    font-size: 13px;
    transition: background-color 0.2s ease;
}

.link-btn:hover {
    background-color: var(--text-secondary);
    color: white;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        margin: 16px;
        padding: 20px;
    }

    .navbar {
        padding: 10px 16px;
    }

    .table {
        font-size: 14px;
    }

    .table th, .table td {
        padding: 8px 12px;
    }
}
