:root {
    --primary-color: #7868E6;
    --secondary-color: #B8B5FF;
    --accent-color: #E4FBFF;
    --background-color: #EDEEF7;
    --error-color: #FFB4B4;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --white: #ffffff;
    --border-radius: 12px;
    --box-shadow: 0 4px 20px rgba(120, 104, 230, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --paper-texture: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><filter id="paper"><feTurbulence baseFrequency="0.04" numOctaves="5" result="noise"/><feColorMatrix in="noise" type="saturate" values="0"/></filter></defs><rect width="100" height="100" filter="url(%23paper)" opacity="0.4"/></svg>');
}

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

body {
    font-family: var(--font-family);
    background-color: var(--background-color);
    background-image: var(--paper-texture);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

.empty-state {
    text-align: center;
    padding: 20px;
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    padding: 1rem 0;
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header__title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header__icon {
    font-size: 2rem;
}

.header__logo {
    display: inline-block;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

.header__nav {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Mobile bottom sheet nav */
.nav-toggle {
    display: none;
}

.mobile-nav {
    position: fixed;
    inset: 0;
    z-index: 1100;
    display: none;
}

.mobile-nav--active {
    display: block;
}

.mobile-nav__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
}

.mobile-nav__sheet {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    background: var(--white);
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    transform: translateY(-100%);
    transition: var(--transition);
    padding-top: calc(0.5rem + env(safe-area-inset-top));
}

.mobile-nav--active .mobile-nav__sheet {
    transform: translateY(0);
}

.mobile-nav__handle {
    width: 40px;
    height: 4px;
    background: var(--background-color);
    border-radius: 4px;
    margin: 10px auto;
}

.mobile-nav__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--background-color);
}

.mobile-nav__title {
    font-size: 1rem;
    color: var(--text-dark);
}

.mobile-nav__close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-light);
}

.mobile-nav__content {
    display: grid;
    gap: 0.35rem;
    padding: 0.5rem 0.75rem 0.75rem;
}

.mobile-nav__content .nav-btn {
    color: var(--primary-color);
    background: var(--accent-color);
    padding: 0.6rem 0.75rem;
    font-size: 0.95rem;
}

.mobile-nav__content .nav-btn.nav-btn--active {
    background: var(--primary-color);
    color: var(--white);
}

/* Desktop: nunca mostrar bottom sheet/toggle */
@media (min-width: 769px) {
    .mobile-nav {
        display: none !important;
    }
    .nav-toggle {
        display: none !important;
    }
}

.nav-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid transparent;
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    backdrop-filter: blur(10px);
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.nav-btn--active {
    background: var(--white);
    color: var(--primary-color);
    border-color: var(--white);
}

.nav-btn__icon {
    font-size: 1.1rem;
}

/* Main Content */
.main {
    flex: 1;
    padding: 2rem 0;
}

.section {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.section--active {
    display: block;
}

.section__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.section__title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* Page content wrappers */
.content {
    max-width: 920px;
    margin: 0 auto;
    padding: 0 16px;
}

.content h3 {
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.content p {
    margin: 0.35rem 0;
}

.content ul {
    margin: 0.5rem 1.25rem;
    padding-left: 1rem;
}

.content a {
    color: var(--primary-color);
    text-decoration: none;
}

.content a:hover {
    text-decoration: underline;
}

.content img,
.content table {
    max-width: 100%;
}

/* Button Styles */
.btn {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.9rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    border: 2px solid transparent;
}

.btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--box-shadow);
}

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

.btn--secondary:hover {
    background: var(--primary-color);
    color: var(--white);
}

.btn--danger {
    background: var(--error-color);
    color: var(--text-dark);
}

.btn--danger:hover {
    background: #ff9999;
}

.btn__icon {
    font-size: 1rem;
}

/* Monochrome icon system */
.icon {
    display: inline-block;
    width: 1em;
    height: 1em;
    vertical-align: -0.125em;
    background: currentColor;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
    -webkit-mask-size: contain;
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: contain;
}

/* Icon masks (SVG data URIs) */
.icon--calendar { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='3' y='4' width='18' height='17' rx='2'/><rect x='3' y='8' width='18' height='3'/><rect x='7' y='2' width='2' height='4'/><rect x='15' y='2' width='2' height='4'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='3' y='4' width='18' height='17' rx='2'/><rect x='3' y='8' width='18' height='3'/><rect x='7' y='2' width='2' height='4'/><rect x='15' y='2' width='2' height='4'/></svg>"); }
.icon--list { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='4' y='6' width='16' height='2'/><rect x='4' y='11' width='16' height='2'/><rect x='4' y='16' width='16' height='2'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='4' y='6' width='16' height='2'/><rect x='4' y='11' width='16' height='2'/><rect x='4' y='16' width='16' height='2'/></svg>"); }
.icon--bell { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 22a2 2 0 0 0 2-2H10a2 2 0 0 0 2 2Z'/><path d='M4 17h16l-2-3v-4a6 6 0 1 0-12 0v4l-2 3Z'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 22a2 2 0 0 0 2-2H10a2 2 0 0 0 2 2Z'/><path d='M4 17h16l-2-3v-4a6 6 0 1 0-12 0v4l-2 3Z'/></svg>"); }
.icon--plus { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='11' y='4' width='2' height='16'/><rect x='4' y='11' width='16' height='2'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='11' y='4' width='2' height='16'/><rect x='4' y='11' width='16' height='2'/></svg>"); }
.icon--edit { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25Z'/><path d='M20.71 7.04a1 1 0 0 0 0-1.41l-2.34-2.34a1 1 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83Z'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25Z'/><path d='M20.71 7.04a1 1 0 0 0 0-1.41l-2.34-2.34a1 1 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83Z'/></svg>"); }
.icon--trash { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M6 7h12l-1 13H7L6 7Z'/><rect x='9' y='3' width='6' height='2'/><rect x='4' y='5' width='16' height='2'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M6 7h12l-1 13H7L6 7Z'/><rect x='9' y='3' width='6' height='2'/><rect x='4' y='5' width='16' height='2'/></svg>"); }
.icon--check { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4Z'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4Z'/></svg>"); }
.icon--undo { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M7 7v4h4l-1.5-1.5a6 6 0 1 1-1.76 4.24h-2A8 8 0 1 0 7 5.34L8.5 3.84 7 2.34V7Z'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M7 7v4h4l-1.5-1.5a6 6 0 1 1-1.76 4.24h-2A8 8 0 1 0 7 5.34L8.5 3.84 7 2.34V7Z'/></svg>"); }
.icon--home { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 3 2 12h3v8h6v-5h2v5h6v-8h3L12 3Z'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 3 2 12h3v8h6v-5h2v5h6v-8h3L12 3Z'/></svg>"); }
.icon--briefcase { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='3' y='7' width='18' height='12' rx='2'/><rect x='8' y='4' width='8' height='3' rx='1'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='3' y='7' width='18' height='12' rx='2'/><rect x='8' y='4' width='8' height='3' rx='1'/></svg>"); }
.icon--user { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><circle cx='12' cy='8' r='4'/><path d='M4 21c0-4 4-6 8-6s8 2 8 6'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><circle cx='12' cy='8' r='4'/><path d='M4 21c0-4 4-6 8-6s8 2 8 6'/></svg>"); }
.icon--triangle { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 4 3 20h18L12 4Z'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 4 3 20h18L12 4Z'/></svg>"); }
.icon--circle { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><circle cx='12' cy='12' r='8'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><circle cx='12' cy='12' r='8'/></svg>"); }
.icon--square { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='6' y='6' width='12' height='12' rx='2'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='6' y='6' width='12' height='12' rx='2'/></svg>"); }
.icon--menu { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='3' y='6' width='18' height='2'/><rect x='3' y='11' width='18' height='2'/><rect x='3' y='16' width='18' height='2'/></svg>"); mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect x='3' y='6' width='18' height='2'/><rect x='3' y='11' width='18' height='2'/><rect x='3' y='16' width='18' height='2'/></svg>"); }

/* Timeline Styles */
.timeline-container {
    position: relative;
    overflow-x: auto;
    padding: 2rem 0;
}

.timeline {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 30px;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-left: 70px;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border-left: 4px solid var(--primary-color);
}

.timeline-item:hover {
    transform: translateX(5px);
    box-shadow: 0 8px 30px rgba(120, 104, 230, 0.2);
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -45px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    border: 4px solid var(--white);
    box-shadow: 0 0 0 4px var(--primary-color);
}

.timeline-item--casa::before {
    background: #ff6b6b;
    box-shadow: 0 0 0 4px #ff6b6b;
}

.timeline-item--trabalho::before {
    background: #4ecdc4;
    box-shadow: 0 0 0 4px #4ecdc4;
}

.timeline-item--bebe::before {
    background: #ffe66d;
    box-shadow: 0 0 0 4px #ffe66d;
}

.timeline-item--pessoal::before {
    background: #a8e6cf;
    box-shadow: 0 0 0 4px #a8e6cf;
}

.timeline-item__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    gap: 1rem;
}

.timeline-item__title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.timeline-item__date {
    font-size: 0.9rem;
    color: var(--text-light);
    background: var(--accent-color);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    white-space: nowrap;
}

.timeline-item__category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.timeline-item__category--casa {
    background: #ffe6e6;
    color: #cc0000;
}

.timeline-item__category--trabalho {
    background: #e6f7f7;
    color: #006666;
}

.timeline-item__category--bebe {
    background: #fff9e6;
    color: #cc8800;
}

.timeline-item__category--pessoal {
    background: #f0f9f0;
    color: #006600;
}

.timeline-item__description {
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.timeline-item__actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Checklist Styles */
.checklist-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.tab-btn {
    background: var(--white);
    color: var(--text-dark);
    border: 2px solid var(--primary-color);
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.tab-btn:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
}

.tab-btn--active {
    background: var(--primary-color);
    color: var(--white);
}

.tab-btn__icon {
    font-size: 1.1rem;
}

.checklist-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.checklist-item {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border-left: 4px solid var(--primary-color);
}

.checklist-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(120, 104, 230, 0.2);
}

.checklist-item--completed {
    opacity: 0.7;
    border-left-color: #27ae60;
}

.checklist-item__header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.checklist-item__checkbox {
    width: 24px;
    height: 24px;
    border: 2px solid var(--primary-color);
    border-radius: 6px;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    margin-top: 0.25rem;
    transition: var(--transition);
}

.checklist-item__checkbox--checked {
    background: var(--primary-color);
}

.checklist-item__checkbox--checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--white);
    font-weight: bold;
    font-size: 14px;
}

.checklist-item__content {
    flex: 1;
}

.checklist-item__title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.checklist-item__description {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.checklist-item__meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.checklist-item__priority {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.checklist-item__priority--alta {
    background: #ffe6e6;
    color: #cc0000;
}

.checklist-item__priority--media {
    background: #fff9e6;
    color: #cc8800;
}

.checklist-item__priority--baixa {
    background: #f0f9f0;
    color: #006600;
}

.checklist-item__actions {
    display: flex;
    gap: 0.5rem;
}

/* Reminders Styles */
.reminder-filters {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.filter-btn {
    background: var(--white);
    color: var(--text-dark);
    border: 2px solid var(--primary-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.9rem;
    font-weight: 500;
}

.filter-btn:hover {
    background: var(--accent-color);
}

.filter-btn--active {
    background: var(--primary-color);
    color: var(--white);
}

.reminders-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.reminder-item {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border-left: 4px solid var(--primary-color);
    position: relative;
}

.reminder-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(120, 104, 230, 0.2);
}

.reminder-item--completed {
    opacity: 0.7;
    border-left-color: #27ae60;
}

.reminder-item--overdue {
    border-left-color: var(--error-color);
}

.reminder-item__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    gap: 1rem;
}

.reminder-item__title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.reminder-item__datetime {
    font-size: 0.9rem;
    color: var(--text-light);
    background: var(--accent-color);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    white-space: nowrap;
}

.reminder-item__description {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.reminder-item__actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.reminder-item__status {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary-color);
}

.reminder-item__status--completed {
    background: #27ae60;
}

.reminder-item__status--overdue {
    background: var(--error-color);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal--active {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-in-out;
}

.modal__content {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 0;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease-out;
}

.modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--background-color);
}

.modal__title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-color);
}

.modal__close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-light);
    padding: 0.5rem;
    border-radius: 50%;
    transition: var(--transition);
}

.modal__close:hover {
    background: var(--background-color);
    color: var(--primary-color);
}

/* Form Styles */
.form {
    padding: 1.5rem;
}

.form__group {
    margin-bottom: 1.5rem;
}

.form__label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-dark);
}

.form__input,
.form__textarea,
.form__select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--background-color);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
}

/* Form error states */
.form__input--error,
.form__textarea--error,
.form__select--error {
    border-color: var(--error-color);
    box-shadow: 0 0 0 3px rgba(255, 180, 180, 0.2);
}

.form__error {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: #b00020;
}

/* Accessibility helpers */
.visually-hidden {
    position: absolute !important;
    height: 1px; width: 1px;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    white-space: nowrap;
}

/* Focus styles */
.btn:focus,
.form__input:focus,
.form__textarea:focus,
.form__select:focus,
.nav-btn:focus,
.tab-btn:focus,
.filter-btn:focus,
.modal__close:focus {
    outline: 3px solid rgba(120, 104, 230, 0.35);
    outline-offset: 2px;
}

/* Layout utilities */
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.pt-1 { padding-top: 0.25rem; }
.pt-2 { padding-top: 0.5rem; }
.pt-3 { padding-top: 1rem; }
.pt-4 { padding-top: 1.5rem; }
.pb-1 { padding-bottom: 0.25rem; }
.pb-2 { padding-bottom: 0.5rem; }
.pb-3 { padding-bottom: 1rem; }
.pb-4 { padding-bottom: 1.5rem; }
.text-center { text-align: center; }
.text-right { text-align: right; }

.form__input:focus,
.form__textarea:focus,
.form__select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(120, 104, 230, 0.1);
}

.form__textarea {
    resize: vertical;
    min-height: 80px;
}

.form__actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

/* Toast Styles */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--primary-color);
    color: var(--white);
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transform: translateY(100px);
    opacity: 0;
    transition: var(--transition);
    z-index: 1001;
    max-width: 400px;
}

.toast--active {
    transform: translateY(0);
    opacity: 1;
}

.toast--success {
    background: #27ae60;
}

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

.toast__content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.toast__icon {
    font-size: 1.2rem;
}

.toast__message {
    flex: 1;
    font-weight: 500;
}

/* Loading Styles */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(5px);
}

.loading--active {
    display: flex;
}

.loading__spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--background-color);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

.loading__text {
    color: var(--primary-color);
    font-weight: 500;
}

/* Footer Styles */
.footer {
    background: var(--primary-color);
    text-align: center;
    color: var(--accent-color);
    padding: 1rem 0;
    text-align: center;
    margin-top: auto;
    font-size: 0.8rem;
    line-height: 1.5;
}

.footer__links p,
.footer__disclaimer,
.footer p {
  margin: 0.5rem 0;
}

/* Footer responsive layout */
.footer .container {
    display: grid;
    gap: 0.75rem;
}

.footer__links {
    display: grid;
    gap: 0.5rem;
}

.footer__bottom {
    margin-top: 0.25rem;
    opacity: 0.95;
}


.footer__text {
    font-size: 0.9rem;
    opacity: 0.9;
}

.footer__link {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.footer__link:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.footer__link-inline {
    color: inherit;
    text-decoration: none;
}
.footer__link-inline:hover {
    text-decoration: underline;
}

/* Footer layout refinement */
.footer__links {
    margin-bottom: 0.25rem;
}
.footer__bottom {
    padding-top: 0.5rem;
    border-top: 1px solid rgba(255,255,255,0.2);
}

/* Back to top floating button */
.back-to-top {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    width: 44px;
    height: 44px;
    display: none;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    background: var(--primary-color);
    color: var(--white);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    cursor: pointer;
    z-index: 1100;
}

.back-to-top--visible {
    display: inline-flex;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header__title {
        font-size: 1.5rem;
        margin-bottom: 0.5rem;
    }
    .header .container {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    
    .header__title {
        margin-bottom: 0;
        flex: 1;
    }
    
    .section__title {
        font-size: 1.6rem;
    }
    
    .section__header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .timeline::before {
        left: 15px;
    }
    
    .timeline-item {
        margin-left: 40px;
    }
    
    .timeline-item::before {
        left: -30px;
        width: 15px;
        height: 15px;
    }

    /* Compact header nav on tablets/smaller screens */
    .header__nav {
        gap: 0.35rem;
    }
    .nav-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.85rem;
        border-radius: 10px;
        gap: 0.35rem;
    }
    .nav-btn__icon {
        font-size: 1rem;
    }
    
    .checklist-content,
    .reminders-container {
        grid-template-columns: 1fr;
    }
    
    .modal__content {
        width: 95%;
        margin: 1rem;
    }

    /* Position modals closer to the top on mobile */
    .modal--active {
        align-items: flex-start;
    }
    .modal--active .modal__content {
        margin-top: 35px;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
    }

    .modal--active .modal__content::before {
        content: '';
        position: sticky;
        top: 0;
        left: 0;
        right: 0;
        height: 12px;
        display: block;
        background: linear-gradient(to bottom, rgba(0,0,0,0.12), rgba(0,0,0,0));
        border-top-left-radius: var(--border-radius);
        border-top-right-radius: var(--border-radius);
        z-index: 1;
    }
    
    .form__actions {
        flex-direction: column;
    }
    
    .form__actions .btn {
        width: 100%;
        justify-content: center;
    }
    
    .toast {
        bottom: 1rem;
        right: 1rem;
        left: 1rem;
        max-width: none;
    }
    .nav-toggle {
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        padding: 0.5rem;
        border-radius: 8px;
    }
    /* hide header inline nav when bottom sheet is present */
    .header__nav {
        display: none;
    }
    .mobile-nav__content .nav-btn {
        padding: 0.55rem 0.65rem;
        font-size: 0.9rem;
        border-radius: 10px;
        gap: 0.35rem;
    }
    .footer .container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .footer__links {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .header__nav {
        justify-content: center;
    }
    
    .nav-btn {
        flex: 1;
        justify-content: center;
        min-width: 0;
        padding: 0.4rem 0.5rem;
        font-size: 0.8rem;
        border-radius: 10px;
        gap: 0.25rem;
    }
    
    .nav-btn__icon {
        margin-right: 0;
        font-size: 0.95rem;
    }
    .header__title {
        font-size: 1.3rem;
    }
    .header {
        padding: 0.75rem 0;
    }
    
    .checklist-tabs,
    .reminder-filters {
        justify-content: center;
    }
    
    .tab-btn,
    .filter-btn {
        flex: 1;
        justify-content: center;
        min-width: 0;
    }
    .footer .container {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }
}

@media (min-width: 769px) {
    .footer .container {
        grid-template-columns: 1fr;
        justify-items: center;
    }
    .footer__links {
        grid-template-columns: repeat(3, minmax(160px, auto));
        align-items: start;
    }
}

/* Print Styles */
@media print {
    .header__nav,
    .section__header .btn,
    .modal,
    .toast,
    .loading {
        display: none !important;
    }
    
    .section {
        display: block !important;
    }
    
    .timeline-item,
    .checklist-item,
    .reminder-item {
        break-inside: avoid;
        margin-bottom: 1rem;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #000080;
        --secondary-color: #4169E1;
        --text-dark: #000000;
        --text-light: #333333;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
