:root {
    --bg-primary: #fff0f5;
    --bg-secondary: #ffffff;
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-border: rgba(255, 93, 143, 0.12);
    --glass-highlight: rgba(255, 93, 143, 0.2);
    --text-main: #2d3748;
    --text-muted: #718096;
    --accent-primary: #ff5d8f;
    --accent-secondary: #ff7b93;
    --accent-gradient: linear-gradient(135deg, #ff5d8f 0%, #ff7b93 100%);
    --card-shadow: 0 10px 40px 0 rgba(255, 93, 143, 0.08);
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    background-color: var(--bg-primary);
    color: var(--text-main);
    font-family: var(--font-body);
    min-height: 100vh;
    overflow-x: hidden;
    margin: 0;
}

.glow-bg {
    position: fixed;
    top: -10%;
    left: -10%;
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, rgba(255, 93, 143, 0.12) 0%, rgba(255, 240, 245, 0) 70%);
    z-index: -1;
    pointer-events: none;
    filter: blur(80px);
}

.glow-bg-2 {
    position: fixed;
    bottom: -10%;
    right: -10%;
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, rgba(162, 155, 254, 0.12) 0%, rgba(255, 240, 245, 0) 70%);
    z-index: -1;
    pointer-events: none;
    filter: blur(80px);
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 45, 85, 0.2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 45, 85, 0.4);
}

.app-layout {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

.sidebar {
    width: 280px;
    background: rgba(255, 255, 255, 0.85);
    border-right: 1px solid var(--glass-border);
    padding: 30px 20px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    backdrop-filter: blur(25px);
    position: sticky;
    top: 0;
    height: 100vh;
    z-index: 10;
}

.sidebar-brand h2 {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -1px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
}

.sidebar-counter {
    background: rgba(255, 45, 85, 0.04);
    border: 1px solid rgba(255, 45, 85, 0.1);
    border-radius: 18px;
    padding: 20px 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.sidebar-counter-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.sidebar-counter .counter-lbl {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-primary);
    font-weight: 700;
}

.counter-days-large {
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.1;
    margin: 5px 0;
    letter-spacing: -1px;
}

.counter-lbl-date {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    color: var(--text-main);
}

.counter-lbl-small {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 5px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}

.nav-item {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 12px 16px;
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    width: 100%;
    text-align: left;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-main);
}

.nav-item.active {
    background: rgba(255, 45, 85, 0.08);
    border-color: rgba(255, 45, 85, 0.2);
    color: var(--accent-primary);
}

.nav-item svg {
    transition: transform 0.3s ease;
}

.nav-item.active svg {
    color: var(--accent-primary);
    transform: scale(1.05);
}

.sidebar-footer {
    text-align: center;
}

.sidebar-footer p {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-primary);
    font-weight: 600;
    opacity: 0.7;
}

.main-content {
    flex-grow: 1;
    padding: 20px;
    height: 100vh;
    box-sizing: border-box;
    overflow: hidden;
    max-width: calc(100vw - 280px);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.main-header-mobile {
    display: none;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 15px;
    margin-bottom: 10px;
}

.main-header-mobile h1 {
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.mobile-counter-summary {
    font-size: 0.85rem;
    background: rgba(255, 93, 143, 0.08);
    border: 1px solid rgba(255, 93, 143, 0.2);
    color: var(--accent-primary);
    padding: 4px 12px;
    border-radius: 50px;
    font-weight: 700;
}

.view-pane {
    display: none;
    opacity: 0;
    transition: opacity 0.4s ease;
    width: 100%;
    flex-direction: column;
    gap: 20px;
    flex-grow: 1;
    min-height: 0;
}

.view-pane.active {
    display: flex;
    opacity: 1;
}

.counter-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 25px 40px;
    width: 100%;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(25px);
}

.counter-card h3 {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-primary);
    margin-bottom: 20px;
    font-weight: 700;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.anniversary-date-text {
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--text-muted);
    margin-left: 6px;
    text-transform: none;
    letter-spacing: 0;
}

.anniversary-countdown-bar {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px dashed rgba(255, 93, 143, 0.2);
    text-align: center;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.countdown-title {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-primary);
    font-weight: 700;
}

.countdown-pills {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.countdown-pill {
    background: rgba(255, 93, 143, 0.05);
    border: 1px solid rgba(255, 93, 143, 0.12);
    border-radius: 12px;
    padding: 6px 14px;
    font-weight: 700;
    color: #ff5d8f;
    font-size: 1.1rem;
    display: flex;
    align-items: baseline;
    gap: 2px;
    box-shadow: 0 2px 8px rgba(255, 93, 143, 0.04);
}

.countdown-unit {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: lowercase;
}

.counter-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
    width: 48%;
    place-self: center;
}

.counter-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.counter-val {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: -1px;
}

.counter-lbl {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-top: 5px;
    font-weight: 600;
}

.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 30px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(25px);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    max-height: 100%;
    min-height: 0;
}

.card-badge {
    background: rgba(255, 45, 85, 0.08);
    border: 1px solid rgba(255, 45, 85, 0.2);
    color: var(--accent-primary);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    width: fit-content;
    margin-bottom: 20px;
}

.glass-card h2 {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.glass-card p {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 10px;
    line-height: 1.5;
}

.roulette-card {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.roulette-layout-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    width: 100%;
}

.roulette-info-side {
    flex: 1.2;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.roulette-info-side h2 {
    margin-top: 0;
}

.roulette-wheel-side {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 460px;
}

.roulette-display {
    background: rgba(255, 255, 255, 0.5);
    border: 1px dashed rgba(255, 93, 143, 0.35);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
    width: 100%;
    box-sizing: border-box;
}

.roulette-display::before {
    content: "▼";
    position: absolute;
    top: 5px;
    left: 50%;
    transform: translateX(-50%) scaleX(1.3);
    color: var(--accent-primary);
    font-size: 1.3rem;
    z-index: 10;
    filter: drop-shadow(0 2px 4px rgba(255, 93, 143, 0.4));
}

.roulette-wheel-container {
    width: 100%;
    max-width: 440px;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border-radius: 50%;
    padding: 6px;
    background: rgba(255, 255, 255, 0.6);
    box-shadow: 0 8px 32px rgba(255, 93, 143, 0.15);
    box-sizing: border-box;
}

#roulette-canvas {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.05);
    will-change: transform;
}

.dare-box {
    background: rgba(255, 93, 143, 0.07);
    border: 1.5px dashed rgba(255, 93, 143, 0.35);
    padding: 16px 20px;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--accent-primary);
    margin: 12px 0 22px 0;
    text-align: center;
    line-height: 1.55;
    box-shadow: 0 4px 12px rgba(255, 93, 143, 0.05);
}

.modal-content p {
    margin-bottom: 12px;
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 25px;
    justify-content: center;
}

.filter-btn {
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 50px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    border-color: rgba(255, 45, 85, 0.3);
    color: var(--text-main);
}

.filter-btn.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 5px 15px rgba(255, 45, 85, 0.3);
}

.action-btn {
    background: var(--accent-gradient);
    border: none;
    color: #ffffff;
    padding: 16px 30px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 5px 20px rgba(255, 45, 85, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 45, 85, 0.45);
}

.action-btn:active {
    transform: translateY(1px);
}

.plan-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.input-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
}

input[type="text"],
input[type="date"],
input[type="time"],
select {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px 16px;
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: all 0.3s ease;
    width: 100%;
}

input[type="text"]:focus,
input[type="date"]:focus,
input[type="time"]:focus,
select:focus {
    border-color: var(--accent-primary);
    outline: none;
    background: #ffffff;
    box-shadow: 0 0 15px rgba(255, 93, 143, 0.15);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
}

.submit-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 12px 24px;
    border-radius: 12px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    background: var(--accent-gradient);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 5px 15px rgba(255, 45, 85, 0.2);
}

.plans-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-grow: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 5px;
}

.plan-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.75);
    border-radius: 16px;
    padding: 16px 20px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.015);
}

.plan-item:hover {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(255, 93, 143, 0.2);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.03);
}

.plan-item.cat-food {
    border-left: 5px solid #f4a261;
}

.plan-item.cat-adventure {
    border-left: 5px solid #2a9d8f;
}

.plan-item.cat-home {
    border-left: 5px solid #9b5de5;
}

.plan-item.cat-relax {
    border-left: 5px solid #457b9d;
}

.plan-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    margin-right: 20px;
}

.plan-name {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
}

.plan-cat-tag {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    width: fit-content;
}

.tag-food {
    background: rgba(244, 162, 97, 0.12);
    color: #f4a261;
}

.tag-adventure {
    background: rgba(42, 157, 143, 0.12);
    color: #2a9d8f;
}

.tag-home {
    background: rgba(155, 93, 229, 0.12);
    color: #9b5de5;
}

.tag-relax {
    background: rgba(69, 123, 157, 0.12);
    color: #457b9d;
}

.plan-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.delete-plan-btn,
.schedule-plan-btn,
.edit-plan-btn,
.save-plan-btn,
.cancel-edit-btn {
    background: rgba(0, 0, 0, 0.03);
    border: none;
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.delete-plan-btn:hover {
    background: rgba(239, 68, 68, 0.08);
    color: #ef4444;
}

.schedule-plan-btn:hover {
    background: rgba(255, 93, 143, 0.08);
    color: var(--accent-primary);
}

.edit-plan-btn:hover {
    background: rgba(143, 45, 255, 0.08);
    color: var(--accent-secondary);
}

.save-plan-btn:hover {
    background: rgba(34, 197, 94, 0.08);
    color: #22c55e;
}

.cancel-edit-btn:hover {
    background: rgba(100, 116, 139, 0.08);
    color: #64748b;
}

.edit-plan-title-input {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    padding: 8px 14px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #1e293b;
    width: 100%;
    max-width: 450px;
    outline: none;
    transition: all 0.2s ease;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.edit-plan-title-input:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(255, 93, 143, 0.15);
}

.edit-plan-category-select {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    padding: 6px 12px;
    font-size: 0.8rem;
    color: #475569;
    width: fit-content;
    outline: none;
}


.agenda-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    flex-grow: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 10px 12px 25px 10px;
}

.agenda-item {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.85);
    border-radius: 18px;
    padding: 24px 20px 20px 20px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.03);
    min-height: 195px;
}

.agenda-item:hover {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(255, 93, 143, 0.3);
    box-shadow: 0 15px 30px rgba(255, 93, 143, 0.1);
}

.agenda-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: transparent;
}

.agenda-item.cat-food::before {
    background: #f4a261;
}

.agenda-item.cat-adventure::before {
    background: #2a9d8f;
}

.agenda-item.cat-home::before {
    background: #9b5de5;
}

.agenda-item.cat-relax::before {
    background: #457b9d;
}

.agenda-main-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}

.agenda-main-content .plan-name {
    font-size: 0.98rem;
    font-weight: 600;
    line-height: 1.5;
    color: #1e293b;
}

.agenda-main-content .plan-cat-tag {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 700;
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    width: fit-content;
}

.agenda-right-content {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.agenda-date-time-badge {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.agenda-date-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #475569;
    display: flex;
    align-items: center;
}

.agenda-date-label svg {
    color: #94a3b8;
    margin-right: 5px;
}

.agenda-time-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: #64748b;
    display: flex;
    align-items: center;
}

.agenda-time-label svg {
    color: #94a3b8;
    margin-right: 5px;
}

.agenda-placeholder {
    font-size: 0.95rem;
    color: var(--text-muted);
    text-align: center;
    padding: 30px 0;
    grid-column: 1 / -1;
}

.cancel-date-btn {
    background: rgba(0, 0, 0, 0.03);
    border: none;
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.cancel-date-btn:hover {
    background: rgba(239, 68, 68, 0.08);
    color: #ef4444;
    transform: scale(1.08);
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-grow: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 5px;
}

.history-item {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 16px 20px;
    margin-bottom: 12px;
    box-shadow: 0 8px 32px 0 rgba(255, 93, 143, 0.03);
    position: relative;
    border-left: 5px solid rgba(255, 93, 143, 0.25);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.history-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 36px 0 rgba(255, 93, 143, 0.07);
    background: rgba(255, 255, 255, 0.7);
}

/* Bordes laterales de categoría */
.history-item.cat-food {
    border-left-color: #f4a261;
}

.history-item.cat-adventure {
    border-left-color: #2a9d8f;
}

.history-item.cat-home {
    border-left-color: #9b5de5;
}

.history-item.cat-relax {
    border-left-color: #457b9d;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    width: 100%;
}

.history-header .plan-name {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--text-main);
    line-height: 1.4;
}

.history-rating {
    display: flex;
    gap: 2px;
    font-size: 1rem;
    white-space: nowrap;
    align-items: center;
}

.history-heart {
    color: #ff2d55;
    text-shadow: 0 0 5px rgba(255, 45, 85, 0.35);
}

/* Badges de Estado */
.status-badge {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 12px;
    white-space: nowrap;
}

.status-badge.status-scheduled {
    background: rgba(69, 123, 157, 0.12);
    color: #457b9d;
}

.status-badge.status-rejected {
    background: rgba(230, 57, 70, 0.12);
    color: #e63946;
}

.status-badge.status-pending {
    background: rgba(244, 162, 97, 0.12);
    color: #f4a261;
}

/* Fila de metadatos */
.history-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    width: 100%;
    margin-top: -2px;
}

.history-date {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
}

/* Comentario como cita de diario */
.history-comment {
    font-size: 0.92rem;
    line-height: 1.5;
    color: #334155;
    background: rgba(255, 93, 143, 0.04);
    border-left: 3px solid var(--accent-primary);
    border-radius: 6px;
    padding: 12px 16px;
    margin-top: 6px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    position: relative;
    text-align: left;
}

.quote-icon-left {
    color: rgba(255, 93, 143, 0.35);
    flex-shrink: 0;
    margin-top: 2px;
}

.history-comment span {
    font-style: italic;
}

.history-placeholder {
    font-size: 0.95rem;
    color: var(--text-muted);
    text-align: center;
    padding: 20px 0;
}

.coupons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    width: 100%;
    flex-grow: 1;
    min-height: 0;
    overflow-y: auto;
    padding-bottom: 20px;
}

.coupon-card {
    height: 170px;
    position: relative;
    cursor: pointer;
    perspective: 800px;
    filter: drop-shadow(0 4px 12px rgba(180, 100, 130, 0.18));
}

.coupon-cover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    z-index: 2;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s ease;
    backface-visibility: hidden;
    background:
        radial-gradient(circle at 0 50%, var(--bg-main, #faf5f7) 12px, transparent 12px),
        radial-gradient(circle at 100% 50%, var(--bg-main, #faf5f7) 12px, transparent 12px),
        linear-gradient(135deg, #fce4ec 0%, #fff0f5 40%, #ffffff 100%);
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
    border-radius: 14px;
}

.coupon-cover::before {
    content: '';
    position: absolute;
    left: 35%;
    top: 15%;
    bottom: 15%;
    width: 2px;
    border-left: 2px dashed rgba(255, 93, 143, 0.25);
}

.coupon-cover-left {
    width: 35%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 10px;
}

.coupon-cover-right {
    width: 65%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 15px 20px;
}

.coupon-number {
    font-family: var(--font-heading);
    font-size: 2.6rem;
    font-weight: 800;
    background: linear-gradient(135deg, #d4788a, #c0566a);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}

.coupon-number-label {
    font-family: var(--font-heading);
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #c0566a;
    font-weight: 700;
}

.coupon-scratch-label {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-primary);
    font-weight: 700;
    background: linear-gradient(90deg, #ff5d8f, #c9506b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: couponPulse 2s ease-in-out infinite;
}

@keyframes couponPulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.coupon-scratch-hint {
    font-size: 0.65rem;
    color: #b88e9e;
    font-weight: 500;
}

.coupon-cover-decoration {
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 0.55rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: rgba(192, 86, 106, 0.3);
    font-weight: 700;
}

.coupon-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    z-index: 1;
    background:
        radial-gradient(circle at 0 50%, var(--bg-main, #faf5f7) 12px, transparent 12px),
        radial-gradient(circle at 100% 50%, var(--bg-main, #faf5f7) 12px, transparent 12px),
        linear-gradient(135deg, #fff5f8 0%, #fce4ec 50%, #fff0f5 100%);
    border-radius: 14px;
}

.coupon-content::before {
    content: '';
    position: absolute;
    left: 35%;
    top: 15%;
    bottom: 15%;
    width: 2px;
    border-left: 2px dashed rgba(255, 93, 143, 0.2);
}

.coupon-content-left {
    width: 35%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 10px;
}

.coupon-content-right {
    width: 65%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px 20px;
    text-align: center;
    gap: 8px;
}

.coupon-valid-label {
    font-size: 0.55rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #c0566a;
    font-weight: 700;
}

.coupon-checkmark {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff5d8f, #c9506b);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
    font-weight: 800;
}

.coupon-reward {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.35;
}

.coupon-code {
    font-size: 0.6rem;
    color: #c0566a;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    font-weight: 600;
    padding: 3px 10px;
    border: 1px dashed rgba(192, 86, 106, 0.35);
    border-radius: 4px;
    background: rgba(255, 93, 143, 0.04);
}

.coupon-card.scratched .coupon-cover {
    transform: rotateY(90deg);
    opacity: 0;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s ease;
}

.modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 240, 245, 0.85);
    backdrop-filter: blur(15px);
}

.modal-content {
    position: relative;
    max-width: 400px;
    width: 90%;
    z-index: 101;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 35px 25px;
    border-radius: 24px;
    transform: scale(0.9);
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    border: 1px solid var(--glass-border);
    background: var(--bg-secondary);
    box-shadow: 0 20px 60px rgba(255, 93, 143, 0.12);
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 32px;
    height: 32px;
    font-size: 1.4rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.02);
}

.modal-close:hover {
    background: rgba(255, 93, 143, 0.08);
    color: var(--accent-primary);
}

.modal-badge {
    background: rgba(255, 93, 143, 0.08);
    border: 1px solid rgba(255, 93, 143, 0.2);
    color: var(--accent-primary);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    width: fit-content;
    margin-bottom: 15px;
}

.modal-icon {
    margin: 10px 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.svg-heart {
    color: var(--accent-primary);
    fill: rgba(255, 93, 143, 0.15);
    animation: heartbeat 1.2s infinite ease-in-out;
}

@keyframes heartbeat {
    0% {
        transform: scale(1);
    }

    14% {
        transform: scale(1.12);
    }

    28% {
        transform: scale(1);
    }

    42% {
        transform: scale(1.12);
    }

    70% {
        transform: scale(1);
    }
}

.plan-selected-text {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    margin: 10px 0 20px 0;
    line-height: 1.4;
    max-width: 100%;
}

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.modal-btn-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    width: 100%;
}

.secondary-btn {
    background: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 12px 18px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
}

.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-main);
    border-color: rgba(255, 93, 143, 0.2);
}

.schedule-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: left;
    width: 100%;
    margin-top: 15px;
}

.app-footer {
    text-align: center;
    margin-top: auto;
    padding: 20px 0 0 0;
}

.app-footer p {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-primary);
    font-weight: 600;
    opacity: 0.7;
}

.confetti {
    position: fixed;
    width: 8px;
    height: 8px;
    background-color: var(--accent-primary);
    z-index: 200;
    border-radius: 50%;
    pointer-events: none;
}

.mobile-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: rgba(255, 255, 255, 0.95);
    border-top: 1px solid var(--glass-border);
    backdrop-filter: blur(25px);
    z-index: 20;
    grid-template-columns: repeat(5, 1fr);
    padding: 5px 10px;
}

.mobile-nav-item {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    gap: 4px;
    transition: all 0.3s ease;
}

.mobile-nav-item svg {
    transition: transform 0.2s ease;
}

.mobile-nav-item span {
    font-size: 0.65rem;
    font-weight: 600;
}

.mobile-nav-item.active {
    color: var(--accent-primary);
}

.mobile-nav-item.active svg {
    transform: scale(1.05);
}

@media (max-width: 900px) {
    .app-layout {
        flex-direction: column;
    }

    .sidebar {
        display: none;
    }

    .main-content {
        padding: 12px;
        max-width: 100%;
        padding-bottom: 100px;
        height: auto;
        overflow: visible;
        gap: 15px;
    }

    .mobile-nav {
        display: flex !important;
        justify-content: space-around;
        align-items: center;
    }

    .mobile-nav-item {
        flex: 1;
        max-width: 80px;
    }

    .main-header-mobile {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
        margin-bottom: 15px;
        padding-bottom: 12px;
    }

    .mobile-logo {
        max-height: 50px;
    }

    .help-btn {
        display: none !important;
    }

    .glass-card {
        padding: 20px 15px;
        border-radius: 16px;
    }

    .counter-card {
        padding: 15px 12px;
        border-radius: 16px;
    }

    .counter-card h3 {
        font-size: 0.75rem;
        letter-spacing: 1px;
    }

    .anniversary-date-text {
        display: block;
        margin-top: 2px;
        font-size: 0.7rem;
    }

    .counter-grid {
        width: 100%;
        max-width: 320px;
        margin: 10px auto 0 auto;
        gap: 8px;
    }

    .counter-val {
        font-size: 1.8rem;
    }

    .counter-lbl {
        font-size: 0.65rem;
    }

    .anniversary-countdown-bar {
        margin-top: 15px !important;
        padding-top: 12px !important;
        gap: 6px !important;
    }

    .anniversary-countdown-bar span {
        font-size: 0.75rem !important;
        letter-spacing: 1px !important;
    }

    .anniversary-countdown-bar div {
        font-size: 1rem !important;
        gap: 10px !important;
    }

    .roulette-layout-container {
        flex-direction: column-reverse;
        gap: 20px;
    }

    .roulette-info-side {
        align-items: center;
        text-align: center;
        width: 100%;
    }

    .roulette-wheel-side {
        max-width: 100%;
        margin: 0 auto;
    }

    .roulette-wheel-container {
        max-width: 290px;
        width: 100%;
    }

    .roulette-display {
        margin-bottom: 0;
        padding: 12px;
        border-radius: 18px;
    }

    .roulette-display::before {
        font-size: 1.1rem;
        top: 3px;
    }

    .action-btn {
        width: 100%;
        padding: 12px 20px;
        font-size: 0.95rem;
    }

    .filter-tags {
        gap: 6px;
    }

    .filter-tag-btn {
        padding: 5px 12px;
        font-size: 0.75rem;
    }
}

.help-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    color: var(--accent-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--card-shadow);
    z-index: 99;
    transition: all 0.3s ease;
}

.help-btn:hover {
    transform: scale(1.05);
    background: var(--accent-gradient);
    color: #ffffff;
    border-color: transparent;
    box-shadow: 0 5px 15px rgba(255, 93, 143, 0.3);
}

.tutorial-card {
    max-width: 450px;
}

.tutorial-slides-container {
    width: 100%;
    position: relative;
    min-height: 250px;
    display: flex;
    align-items: center;
}

.tutorial-slide {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.tutorial-slide.active {
    display: flex;
    opacity: 1;
}

.tutorial-icon-wrapper {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 93, 143, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    color: var(--accent-primary);
    border: 1px solid rgba(255, 93, 143, 0.15);
}

.tutorial-slide h2 {
    margin-bottom: 10px;
    font-size: 1.5rem;
    color: var(--text-main);
}

.tutorial-slide p {
    color: var(--text-muted);
    line-height: 1.6;
    font-size: 0.95rem;
    margin-bottom: 0;
}

.tutorial-navigation {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-top: 30px;
    gap: 15px;
}

.tutorial-dots {
    display: flex;
    gap: 8px;
}

.tutorial-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 93, 143, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
}

.tutorial-dot.active {
    background: var(--accent-primary);
    transform: scale(1.2);
}

.mobile-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-help-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 93, 143, 0.08);
    border: 1px solid rgba(255, 93, 143, 0.2);
    color: var(--accent-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.mobile-help-btn:active {
    background: var(--accent-gradient);
    color: #ffffff;
    border-color: transparent;
    transform: scale(0.9);
}

.sidebar-brand {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.sidebar-logo {
    max-width: 90%;
    height: auto;
    max-height: 110px;
    object-fit: contain;
}

.mobile-logo {
    max-height: 60px;
    width: auto;
    object-fit: contain;
}

.roulette-filters {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.filter-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.filter-tag-btn {
    background: rgba(255, 255, 255, 0.45);
    border: 1px solid var(--glass-border);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.filter-tag-btn:hover {
    background: rgba(255, 255, 255, 0.75);
    color: var(--text-color);
}

.filter-tag-btn.active {
    background: #ffffff;
    border-color: rgba(255, 93, 143, 0.4);
    box-shadow: 0 4px 10px rgba(255, 93, 143, 0.15);
    color: var(--accent-primary);
}

.tag-color-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.tag-color-dot.food {
    background: #f4a261;
}

.tag-color-dot.adventure {
    background: #2a9d8f;
}

.tag-color-dot.home {
    background: #9b5de5;
}

.tag-color-dot.relax {
    background: #457b9d;
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 25px;
    width: 100%;
}

.stat-box {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 16px;
    padding: 15px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
    transition: all 0.3s ease;
}

.stat-box:hover {
    background: rgba(255, 255, 255, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(255, 93, 143, 0.08);
}

.stat-icon {
    font-size: 1.2rem;
    margin-bottom: 4px;
    filter: drop-shadow(0 2px 4px rgba(255, 93, 143, 0.2));
}

.stat-value {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 3px;
}

.hearts-rating-container {
    display: flex;
    gap: 8px;
    font-size: 2rem;
    cursor: pointer;
    user-select: none;
    margin-top: 5px;
}

.heart-rate-item {
    color: #e2e8f0;
    transition: transform 0.2s ease, color 0.2s ease;
}

.heart-rate-item:hover {
    transform: scale(1.15);
}

.heart-rate-item.active {
    color: #ff2d55;
    text-shadow: 0 0 10px rgba(255, 45, 85, 0.3);
}

.plan-item.is-favorite {
    background: rgba(255, 235, 240, 0.75);
    border-color: rgba(255, 93, 143, 0.35);
    box-shadow: 0 4px 15px rgba(255, 93, 143, 0.08);
}

.plan-item.is-favorite:hover {
    background: rgba(255, 235, 240, 0.9);
    border-color: rgba(255, 93, 143, 0.5);
    box-shadow: 0 6px 22px rgba(255, 93, 143, 0.15);
}

.favorite-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cbd5e1;
    transition: all 0.2s ease;
}

.favorite-btn:hover {
    background: rgba(255, 45, 85, 0.08);
    transform: scale(1.1);
}

.favorite-btn.active {
    color: #ff2d55;
    filter: drop-shadow(0 0 4px rgba(255, 45, 85, 0.4));
}

.complete-date-btn {
    background: rgba(52, 199, 89, 0.08);
    border: 1.5px solid rgba(52, 199, 89, 0.2);
    color: #34c759;
    padding: 6px 14px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.complete-date-btn:hover {
    background: #34c759;
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(52, 199, 89, 0.25);
    transform: translateY(-1px);
}

@media (max-width: 600px) {
    .stats-container {
        grid-template-columns: 1fr;
        gap: 10px;
    }
}

/* --- LOGIN SCREEN --- */
#login-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at top left, #ffeef2, #fff0f5, #f5e6ff);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 20px;
    box-sizing: border-box;
}

#login-screen .login-card {
    max-width: 400px;
    width: 100%;
    padding: 40px 30px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(255, 75, 110, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.7);
}

.login-header {
    margin-bottom: 30px;
}

.login-logo {
    max-width: 130px;
    height: auto;
    margin-bottom: 15px;
    filter: drop-shadow(0 4px 6px rgba(255, 75, 110, 0.1));
}

.login-header h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 5px 0;
    letter-spacing: -0.5px;
}

.login-header p {
    font-size: 0.9rem;
    color: var(--text-soft);
    margin: 0;
}

.form-group {
    text-align: left;
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    border: 1.5px solid rgba(255, 75, 110, 0.15);
    background: rgba(255, 255, 255, 0.5);
    color: var(--text-main);
    font-size: 0.95rem;
    font-family: inherit;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(255, 45, 85, 0.1);
}

.login-btn {
    width: 100%;
    margin-top: 10px;
    padding: 14px;
    font-size: 1rem;
}

.login-error-msg {
    color: #ff3b30;
    background: rgba(255, 59, 48, 0.08);
    border: 1px solid rgba(255, 59, 48, 0.15);
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.4;
}

.logout-btn-link {
    background: none;
    border: none;
    color: var(--text-soft);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    border-radius: 20px;
    transition: all 0.2s ease;
    width: fit-content;
}

.logout-btn-link:hover {
    color: var(--accent-primary);
    background: rgba(255, 45, 85, 0.05);
}

.btn-logout-mobile {
    margin-left: 5px;
}

/* --- CENTRADO EN FORMULARIO DE RECUERDOS --- */
#memory-form {
    text-align: center;
}

#memory-form .input-group {
    align-items: center;
}

#memory-form label {
    text-align: center;
}

#memory-form .hearts-rating-container {
    justify-content: center;
}

#memory-form textarea {
    text-align: center;
}

/* --- SECCIÓN DE VIAJES --- */
.trips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    width: 100%;
    margin-top: 10px;
}

.trip-card {
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 24px;
    padding: 22px 24px;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    text-align: left;
    box-shadow: var(--card-shadow);
}

.trip-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 93, 143, 0.35);
    box-shadow: 0 15px 35px rgba(255, 93, 143, 0.12);
}

.trip-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 12px;
}

.trip-card-badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--accent-primary);
    background: rgba(255, 93, 143, 0.08);
    border-radius: 100px;
    border: 1px solid rgba(255, 93, 143, 0.15);
}

.trip-card-countdown-badge {
    padding: 4px 10px;
    font-size: 0.68rem;
    font-weight: 700;
    border-radius: 100px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.trip-card-countdown-badge.future {
    background: rgba(255, 93, 143, 0.08);
    color: var(--accent-primary);
    border: 1px solid rgba(255, 93, 143, 0.15);
}

.trip-card-countdown-badge.today {
    background: linear-gradient(135deg, #ff4d6d 0%, #ff7b93 100%);
    color: #ffffff;
    box-shadow: 0 3px 10px rgba(255, 77, 109, 0.3);
}

.trip-card-countdown-badge.tomorrow {
    background: linear-gradient(135deg, #ff7b93 0%, #ff9ebb 100%);
    color: #ffffff;
    box-shadow: 0 3px 10px rgba(255, 123, 147, 0.2);
}

.trip-card-countdown-badge.running {
    background: rgba(46, 204, 113, 0.1);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.2);
}

.trip-card-status-badge.completed {
    padding: 4px 10px;
    font-size: 0.68rem;
    font-weight: 700;
    border-radius: 100px;
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-muted);
    border: 1px solid rgba(0, 0, 0, 0.08);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.trip-card-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 4px 0;
    line-height: 1.3;
}

.trip-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 16px;
    border-top: 1px dashed rgba(255, 93, 143, 0.12);
    padding-top: 14px;
}

.trip-card-dates {
    display: inline-flex;
    align-items: center;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-muted);
}

.trip-card-arrow {
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    opacity: 0.5;
}

.trip-card:hover .trip-card-arrow {
    color: var(--accent-primary);
    transform: translateX(4px);
    opacity: 1;
}

/* Viajes Completados */
.trip-card.completed {
    border-color: rgba(0, 0, 0, 0.08);
    background: rgba(255, 255, 255, 0.3);
}

.trip-card.completed:hover {
    border-color: rgba(0, 0, 0, 0.15);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.04);
}

.trip-card.completed .trip-card-badge {
    color: var(--text-muted);
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.08);
}

.trip-card.completed .trip-card-footer {
    border-top-color: rgba(0, 0, 0, 0.06);
}

.trip-card.completed:hover .trip-card-arrow {
    color: var(--text-main);
}

.trip-empty-card {
    text-align: center;
    padding: 50px 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.trip-empty-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
    filter: drop-shadow(0 4px 10px rgba(255, 93, 143, 0.15));
    animation: float 3s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

.trip-header-card {
    display: flex;
    flex-direction: column;
}

.trip-header-main {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    width: 100%;
}

.trip-header-card h2 {
    font-size: 1.6rem;
    font-weight: 800;
    margin: 5px 0 0 0;
    color: var(--text-main);
}

.trip-planner-card {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.planner-tabs {
    display: flex;
    gap: 10px;
    border-bottom: 1.5px solid var(--glass-border);
    padding-bottom: 10px;
    width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
    /* Firefox */
}

.planner-tabs::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

.planner-tab-btn {
    background: transparent;
    border: none;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.planner-tab-btn.active {
    background: rgba(255, 45, 85, 0.08);
    color: var(--accent-primary);
}

.planner-tab-btn:hover:not(.active) {
    background: rgba(255, 255, 255, 0.5);
    color: var(--text-main);
}

.planner-tab-content {
    display: none;
    flex-direction: column;
    width: 100%;
}

.planner-tab-content.active {
    display: flex;
}

/* Progress bar */
.progress-bar-wrapper {
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 12px 16px;
    margin-bottom: 20px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.progress-info span:last-child {
    color: var(--accent-primary);
}

.progress-bar-outer {
    width: 100%;
    height: 8px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    overflow: hidden;
}

.progress-bar-inner {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 10px;
    transition: width 0.4s cubic-bezier(0.1, 0.8, 0.3, 1);
}

/* Timeline */
.itinerary-timeline {
    position: relative;
    padding-left: 20px;
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.itinerary-timeline::before {
    content: "";
    position: absolute;
    top: 5px;
    left: 4px;
    bottom: 5px;
    width: 2px;
    background: rgba(255, 93, 143, 0.2);
}

.timeline-item {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.35);
    border: 1px solid var(--glass-border);
    padding: 10px 14px;
    border-radius: 12px;
    gap: 10px;
}

.timeline-item::before {
    content: "";
    position: absolute;
    left: -20px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--accent-primary);
    border: 2px solid var(--bg-primary);
    box-shadow: 0 0 0 3px rgba(255, 93, 143, 0.15);
}

.timeline-time {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent-primary);
    background: rgba(255, 93, 143, 0.08);
    padding: 2px 6px;
    border-radius: 6px;
    white-space: nowrap;
}

.timeline-content {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-main);
    flex-grow: 1;
}

.timeline-date-header {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 10px;
    margin-bottom: 5px;
}

/* Checklist items */
.checklist-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.checklist-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--glass-border);
    padding: 12px 16px;
    border-radius: 12px;
    gap: 12px;
    transition: background-color 0.2s ease;
}

.checklist-item.completed {
    background: rgba(255, 255, 255, 0.15);
    opacity: 0.75;
}

.checklist-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-grow: 1;
    cursor: pointer;
}

.checklist-checkbox {
    width: 20px;
    height: 20px;
    border-radius: 6px;
    border: 1.5px solid rgba(255, 93, 143, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    transition: all 0.2s ease;
}

.checklist-item.completed .checklist-checkbox {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
}

.checklist-text {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-main);
    transition: text-shadow 0.2s ease;
}

.checklist-item.completed .checklist-text {
    text-decoration: line-through;
    color: var(--text-muted);
}

.item-delete-btn {
    background: none;
    border: none;
    color: var(--text-soft);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.item-delete-btn:hover {
    color: #ff3b30;
    background: rgba(255, 59, 48, 0.08);
}

@media (max-width: 600px) {
    .trip-header-main {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 15px;
    }

    .trip-header-actions {
        justify-content: center;
    }
}

/* --- DATEPICKER PERSONALIZADO --- */
.custom-datepicker-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 100%;
}

.custom-datepicker-input {
    width: 100% !important;
    padding: 12px 40px 12px 12px !important;
    border-radius: 12px !important;
    border: 1.5px solid rgba(255, 75, 110, 0.15) !important;
    background: rgba(255, 255, 255, 0.5) !important;
    box-sizing: border-box !important;
    font-family: inherit !important;
    font-size: 0.95rem !important;
    font-weight: 500 !important;
    color: var(--text-main) !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
}

.custom-datepicker-input:focus {
    outline: none !important;
    border-color: var(--accent-primary) !important;
    background: rgba(255, 255, 255, 0.8) !important;
    box-shadow: 0 0 0 3px rgba(255, 93, 143, 0.15) !important;
}

.custom-datepicker-icon-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-soft);
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-datepicker-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 8px;
    width: 280px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(180, 100, 130, 0.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 9999 !important;
    padding: 16px;
    box-sizing: border-box;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    opacity: 0;
}

.custom-datepicker-dropdown.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.datepicker-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.datepicker-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--text-main);
}

.datepicker-nav-btn {
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
}

.datepicker-nav-btn:hover {
    background: rgba(255, 93, 143, 0.08);
    color: var(--accent-primary);
}

.datepicker-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.datepicker-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    row-gap: 4px;
    column-gap: 4px;
}

.datepicker-day {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-main);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.datepicker-day:hover:not(.disabled):not(.other-month) {
    background: rgba(255, 93, 143, 0.08);
    color: var(--accent-primary);
}

.datepicker-day.today {
    border: 1.5px solid var(--accent-primary);
    color: var(--accent-primary);
}

.datepicker-day.selected {
    background: linear-gradient(135deg, var(--accent-primary) 0%, #ff7b93 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 10px rgba(255, 93, 143, 0.3);
}

.datepicker-day.other-month {
    color: var(--text-light);
    cursor: default;
    pointer-events: none;
    opacity: 0.3;
}

.datepicker-day.disabled {
    color: var(--text-light);
    cursor: not-allowed;
    pointer-events: none;
    opacity: 0.25;
    text-decoration: line-through;
}

/* Backdrop para Datepicker en móviles */
.datepicker-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 9998 !important;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.datepicker-backdrop.active {
    opacity: 1;
    pointer-events: auto;
}

@media (max-width: 600px) {
    .custom-datepicker-dropdown {
        position: fixed !important;
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -40%) scale(0.9) !important;
        width: 90% !important;
        max-width: 320px !important;
        margin-top: 0 !important;
        border-radius: 24px !important;
        box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25) !important;
        z-index: 9999 !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }

    .custom-datepicker-dropdown.active {
        transform: translate(-50%, -50%) scale(1) !important;
    }
}

/* Modales de Alerta y Confirmación Personalizados */
.custom-alert-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.custom-alert-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.custom-alert-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.55);
}

.custom-alert-content {
    position: relative;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 28px 24px;
    width: 90%;
    max-width: 340px;
    text-align: center;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    transform: scale(0.9);
    transition: transform 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
    z-index: 10001;
}

.custom-alert-modal.active .custom-alert-content {
    transform: scale(1);
}

.custom-alert-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 10px;
}

.custom-alert-message {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 24px;
}

.custom-alert-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.custom-alert-btn {
    flex: 1;
    padding: 12px 18px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.custom-alert-btn.cancel-btn {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-main);
}

.custom-alert-btn.cancel-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

.custom-alert-btn.confirm-btn {
    background: var(--accent-gradient);
    color: #ffffff;
}

.custom-alert-btn.confirm-btn:hover {
    box-shadow: 0 4px 12px rgba(255, 93, 143, 0.2);
    transform: translateY(-1px);
}