/* =========================================================
   爱提醒 · Sunrise Planner 视觉主题
   仅覆盖视觉样式，不改变提醒逻辑与页面结构
   ========================================================= */

[data-theme="sunrise"] {
    --bg-body: #fff8ec;
    --card-bg: rgba(255, 253, 247, .9);
    --card-border: #f4dfc5;
    --card-shadow: 0 14px 38px rgba(166, 102, 42, .1);
    --input-bg: #fffdf9;
    --input-border: #ecd8be;
    --input-focus-border: #ef8859;
    --input-focus-shadow: rgba(239, 136, 89, .18);
    --placeholder-color: #b5a18d;
    --btn-primary-bg: #ef7b52;
    --btn-primary-shadow: rgba(239, 123, 82, .25);
    --btn-secondary-border: #efd4b9;
    --btn-secondary-text: #805738;
    --btn-secondary-hover-bg: rgba(239, 123, 82, .08);
    --icon-color: #c75e3d;
    --gradient-title: linear-gradient(135deg, #d8553c 0%, #ef9a45 58%, #ecba55 100%);
    --status-bg: rgba(239, 123, 82, .09);
    --status-border: rgba(239, 123, 82, .18);
    --status-color: #76412c;
    --footer-color: #aa9079;
    --delete-color: #c26855;
    --delete-hover-color: #b53b35;
    --card-hover-border: #f0c89d;
    --card-hover-shadow: 0 22px 50px rgba(166, 102, 42, .16);
    --sun-coral: #ef7b52;
    --sun-gold: #f2b84b;
    --sun-cream: #fff3dc;
    --sun-ink: #463329;
    font-family: "Inter", "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
}

[data-theme="sunrise"] body {
    position: relative;
    padding: 24px !important;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 88% 0%, rgba(255, 204, 87, .28), transparent 25rem),
        radial-gradient(circle at 2% 18%, rgba(239, 123, 82, .12), transparent 24rem),
        radial-gradient(circle at 76% 90%, rgba(255, 226, 176, .35), transparent 28rem),
        linear-gradient(145deg, #fffaf1 0%, #fff5e9 52%, #fffaf7 100%) !important;
    color: var(--sun-ink) !important;
}

[data-theme="sunrise"] body::before {
    content: "";
    position: fixed;
    top: -190px;
    right: -150px;
    width: 430px;
    height: 430px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    background: radial-gradient(circle, rgba(255, 205, 93, .2) 0%, rgba(255, 205, 93, .06) 44%, transparent 70%);
}

[data-theme="sunrise"] body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: .26;
    background-image: radial-gradient(rgba(177, 116, 68, .2) .75px, transparent .75px);
    background-size: 18px 18px;
    mask-image: linear-gradient(to bottom, rgba(0,0,0,.65), transparent 72%);
}

[data-theme="sunrise"] .container {
    position: relative;
    z-index: 1;
    max-width: 1240px;
}

[data-theme="sunrise"] .header-bar {
    position: relative;
    padding: 16px 24px !important;
    border: 1px solid rgba(255, 255, 255, .92) !important;
    border-radius: 22px !important;
    background: linear-gradient(135deg, rgba(255, 255, 255, .82), rgba(255, 248, 236, .76)) !important;
    box-shadow: 0 14px 38px rgba(148, 94, 47, .1), inset 0 1px 0 #fff !important;
    backdrop-filter: blur(16px);
}

[data-theme="sunrise"] .header-bar::before {
    content: "";
    position: absolute;
    left: 25px;
    bottom: 0;
    width: 76px;
    height: 3px;
    border-radius: 999px 999px 0 0;
    background: linear-gradient(90deg, var(--sun-coral), var(--sun-gold));
    box-shadow: 0 3px 12px rgba(239, 123, 82, .28);
}

[data-theme="sunrise"] .header-bar h1 {
    color: #463329 !important;
    background: none !important;
    -webkit-text-fill-color: currentColor !important;
    font-size: 1.75rem !important;
    letter-spacing: -.02em;
    text-shadow: none;
}

[data-theme="sunrise"] .header-bar h1 i {
    color: var(--sun-coral) !important;
    -webkit-text-fill-color: var(--sun-coral) !important;
    filter: drop-shadow(0 5px 10px rgba(239, 123, 82, .2));
}

[data-theme="sunrise"] .header-bar h1 .user-level {
    border: 1px solid #efddc9 !important;
    background: #fffaf1 !important;
    color: #8b6c55 !important;
    -webkit-text-fill-color: #8b6c55 !important;
    font-size: .72rem !important;
    font-weight: 700 !important;
}

[data-theme="sunrise"] .header-bar h1 .user-level.vip {
    border-color: #edcf85 !important;
    background: #fff2c9 !important;
    color: #8a6600 !important;
    -webkit-text-fill-color: #8a6600 !important;
}

[data-theme="sunrise"] .header-bar a {
    color: #756052 !important;
    border: 1px solid transparent;
}

[data-theme="sunrise"] .header-bar a:hover {
    border-color: rgba(239, 123, 82, .15);
    background: rgba(239, 123, 82, .075) !important;
    color: #bd5637 !important;
}

[data-theme="sunrise"] .theme-selector {
    border-color: #efdbc5 !important;
    background: rgba(255, 255, 255, .7) !important;
    color: #8b6c55 !important;
}

[data-theme="sunrise"] .theme-selector select {
    color: #795d49 !important;
}

[data-theme="sunrise"] .theme-selector select option {
    background: #fffaf2;
    color: #463329;
}

[data-theme="sunrise"] .card-form,
[data-theme="sunrise"] .card-reminder {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .95) !important;
    border-left: 6px solid rgba(239, 123, 82, .78) !important;
    border-radius: 22px !important;
    background: linear-gradient(145deg, rgba(255, 254, 249, .95), rgba(255, 249, 238, .9)) !important;
    box-shadow: 0 14px 36px rgba(154, 98, 49, .1) !important;
    color: #463329 !important;
}

[data-theme="sunrise"] .card-form::before,
[data-theme="sunrise"] .card-reminder::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 92px;
    height: 92px;
    border-radius: 0 0 0 100%;
    background: linear-gradient(135deg, rgba(255, 219, 139, .26), rgba(239, 123, 82, .04));
    pointer-events: none;
}

[data-theme="sunrise"] .card-reminder:hover {
    transform: translateY(-5px) !important;
    border-color: #eecaa3 !important;
    border-left-color: var(--sun-coral) !important;
    box-shadow: 0 22px 48px rgba(154, 98, 49, .16) !important;
}

[data-theme="sunrise"] .card-reminder * {
    color: #463329 !important;
}

[data-theme="sunrise"] .reminder-content {
    color: #4d392e !important;
}

[data-theme="sunrise"] .reminder-meta,
[data-theme="sunrise"] .reminder-email {
    color: #967a65 !important;
}

[data-theme="sunrise"] .reminder-status {
    border: 1px solid #edd5bd !important;
    background: #fff4e6 !important;
    color: #bb5f40 !important;
}

[data-theme="sunrise"] .gradient-title,
[data-theme="sunrise"] .card-form h1,
[data-theme="sunrise"] .card-form h2 {
    color: #463329 !important;
    background: none !important;
    -webkit-text-fill-color: currentColor !important;
}

[data-theme="sunrise"] .btn-primary,
[data-theme="sunrise"] button[type="submit"] {
    border: 0 !important;
    background: linear-gradient(135deg, #ee7650, #f2ad45) !important;
    color: #fff !important;
    box-shadow: 0 9px 24px rgba(239, 123, 82, .23) !important;
}

[data-theme="sunrise"] .btn-primary:hover,
[data-theme="sunrise"] button[type="submit"]:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
    box-shadow: 0 13px 30px rgba(239, 123, 82, .3) !important;
}

[data-theme="sunrise"] .btn-secondary {
    border-color: #efdbc5 !important;
    background: rgba(255, 255, 255, .78) !important;
    color: #805738 !important;
}

[data-theme="sunrise"] input,
[data-theme="sunrise"] textarea,
[data-theme="sunrise"] select,
[data-theme="sunrise"] .form-control,
[data-theme="sunrise"] .form-select {
    border-color: #ecd8be !important;
    background: #fffdf9 !important;
    color: #463329 !important;
}

[data-theme="sunrise"] input::placeholder,
[data-theme="sunrise"] textarea::placeholder {
    color: #b5a18d !important;
}

[data-theme="sunrise"] input:focus,
[data-theme="sunrise"] textarea:focus,
[data-theme="sunrise"] select:focus,
[data-theme="sunrise"] .form-control:focus,
[data-theme="sunrise"] .form-select:focus {
    border-color: #ef8859 !important;
    box-shadow: 0 0 0 3px rgba(239, 136, 89, .14) !important;
}

[data-theme="sunrise"] .table,
[data-theme="sunrise"] .table > :not(caption) > * > * {
    --bs-table-bg: transparent;
    --bs-table-color: #49372c;
    --bs-table-border-color: #f0e2d1;
    color: #49372c !important;
    border-color: #f0e2d1 !important;
}

[data-theme="sunrise"] .table thead th {
    color: #a64e32 !important;
    background: #fff2df !important;
}

[data-theme="sunrise"] .stat-card,
[data-theme="sunrise"] .admin-panel {
    border: 1px solid #f0dfca !important;
    border-radius: 20px !important;
    background: rgba(255, 253, 248, .9) !important;
    box-shadow: 0 12px 32px rgba(150, 97, 51, .09) !important;
    color: #463329 !important;
}

[data-theme="sunrise"] .stat-card .num,
[data-theme="sunrise"] .admin-title {
    color: #c15c3d !important;
}

[data-theme="sunrise"] .stat-card .lbl,
[data-theme="sunrise"] .admin-sub {
    color: #9a806d !important;
}

[data-theme="sunrise"] .alert {
    border: 1px solid #efdbc5;
    border-radius: 16px;
    background: rgba(255, 252, 246, .94);
    color: #5e4738;
}

[data-theme="sunrise"] .footer-note {
    color: #a48b77 !important;
    letter-spacing: .08em;
}

@media (max-width: 900px) {
    [data-theme="sunrise"] .header-bar {
        align-items: flex-start !important;
    }

    [data-theme="sunrise"] .header-center {
        flex-wrap: wrap !important;
        justify-content: flex-start !important;
    }
}

@media (max-width: 720px) {
    [data-theme="sunrise"] body { padding: 12px !important; }
    [data-theme="sunrise"] .header-bar { padding: 15px !important; border-radius: 18px !important; }
    [data-theme="sunrise"] .header-bar h1 { font-size: 1.45rem !important; }
}

/* Mobile layout guard: keep the theme selector inside the viewport. */
@media (max-width: 720px) {
    [data-theme="sunrise"] .header-bar {
        flex-wrap: wrap !important;
        align-items: center !important;
    }

    [data-theme="sunrise"] .header-bar h1 {
        flex: 1 0 100% !important;
        width: 100% !important;
        white-space: normal !important;
    }

    [data-theme="sunrise"] .theme-selector {
        order: 2;
        max-width: 100%;
        margin-left: auto;
    }

    [data-theme="sunrise"] .header-center {
        order: 3;
        flex: 1 0 100% !important;
        width: 100% !important;
    }
}

/* =========================================================
   2026-10-27 · 独立框架版：日程工作台 + 双层顶部导航
   导航与页面框架全局生效，切换 Boss 绿等主题时仍保持此布局
   ========================================================= */

body.atx-shell {
    min-height: 100vh;
    margin: 0;
    padding: 0 !important;
    background: var(--bg-body) !important;
}

.atx-frame { min-height: 100vh; }

.atx-topbar {
    position: sticky;
    top: 0;
    z-index: 120;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
    min-height: 76px;
    padding: 10px 28px;
    border-bottom: 1px solid var(--card-border);
    background: var(--card-bg);
    background: color-mix(in srgb, var(--card-bg) 92%, #ffffff 8%);
    box-shadow: 0 8px 28px rgba(122, 78, 44, .07);
    backdrop-filter: blur(20px);
}
[data-theme="sunrise"] .atx-topbar {
    border-bottom-color: rgba(231, 207, 182, .75);
    background: rgba(255, 252, 246, .9);
}
.atx-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--icon-color);
    text-decoration: none;
}
.atx-brand:hover { color: var(--icon-color); text-decoration: none; }
.atx-brand-icon {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    border: 1px solid rgba(239, 123, 82, .24);
    box-shadow: 0 8px 20px rgba(239, 123, 82, .18);
}
.atx-brand-icon img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}
.atx-brand-copy { display: flex; flex-direction: column; line-height: 1.12; }
.atx-brand-copy strong { font-size: 1rem; font-weight: 900; letter-spacing: -.02em; }
.atx-brand-copy small { margin-top: 3px; color: var(--footer-color); font-family: Consolas, monospace; font-size: .48rem; font-weight: 900; letter-spacing: .14em; }
.atx-nav {
    width: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-wrap: nowrap;
}
.atx-nav a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 11px !important;
    border-bottom: 2px solid transparent;
    border-radius: 8px 8px 0 0;
    color: var(--btn-secondary-text) !important;
    font-size: .94rem !important;
    font-weight: 800 !important;
    text-decoration: none;
    white-space: nowrap;
}
.atx-nav a:hover {
    border-bottom-color: var(--icon-color);
    background: var(--btn-secondary-hover-bg) !important;
    color: var(--icon-color) !important;
}
.atx-nav a:first-child { border-bottom-color: var(--icon-color); color: var(--icon-color) !important; }
.atx-account { display: flex; align-items: center; justify-content: flex-end; gap: 9px; min-width: 0; }
.atx-user {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 5px 9px 5px 5px;
    border: 1px solid var(--card-border);
    border-radius: 999px;
    background: rgba(255, 255, 255, .4);
}
.atx-user-avatar {
    width: 29px;
    height: 29px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 50%;
    color: #fff;
    background: linear-gradient(135deg, #d85b3d, #eea942);
    font-size: .72rem;
    font-weight: 900;
}
.atx-user-copy { display: flex; flex-direction: column; min-width: 0; line-height: 1.15; }
.atx-user-copy b { max-width: 170px; overflow: hidden; color: var(--icon-color); font-size: .68rem; text-overflow: ellipsis; white-space: nowrap; }
.atx-user-copy small { margin-top: 2px; color: var(--footer-color); font-size: .52rem; white-space: nowrap; }
.atx-account .theme-selector { padding: 6px 9px; font-size: .7rem; }
.atx-account .theme-selector select { font-size: .68rem; }
.atx-ribbon {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    min-height: 34px;
    padding: 6px 30px;
    border-bottom: 1px solid var(--card-border);
    color: var(--footer-color);
    background: rgba(255, 255, 255, .32);
    font-size: .63rem;
}
[data-theme="sunrise"] .atx-ribbon { background: rgba(255, 246, 231, .58); }
.atx-live { display: inline-flex; align-items: center; gap: 7px; color: #97644c; font-weight: 800; }
.atx-live i { width: 7px; height: 7px; border-radius: 50%; background: #2fbf71; box-shadow: 0 0 0 4px rgba(47, 191, 113, .12); }
.atx-ribbon-copy { font-family: Consolas, monospace; font-size: .5rem; font-weight: 900; letter-spacing: .16em; }

.container.atx-workspace {
    max-width: 1220px !important;
    margin: 0 auto !important;
    padding: 28px 26px 20px;
}
.atx-content { min-height: calc(100vh - 200px); }

.atx-planner { display: flex; flex-direction: column; }
.atx-plan-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
    padding: 0 2px;
}
.atx-eyebrow { color: #b27050; font-family: Consolas, monospace; font-size: .56rem; font-weight: 900; letter-spacing: .18em; }
.atx-plan-head h2 { display: flex; align-items: center; gap: 10px; margin: 6px 0 5px; color: var(--icon-color); font-size: clamp(1.65rem, 4vw, 2.4rem); font-weight: 900; letter-spacing: -.045em; }
.atx-plan-head h2 i { color: var(--sun-coral, #ef7b52); }
.atx-plan-head p { margin: 0; color: var(--footer-color); font-size: .82rem; }
.atx-create-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 10px 18px;
    border-radius: 12px;
    color: #fff !important;
    background: linear-gradient(135deg, var(--sun-coral, #ef7b52), var(--sun-gold, #f2b84b));
    box-shadow: 0 10px 24px rgba(239, 123, 82, .21);
    font-size: .82rem;
    font-weight: 900;
    text-decoration: none;
    white-space: nowrap;
}
.atx-create-btn:hover { filter: brightness(1.05); transform: translateY(-1px); text-decoration: none; }
.atx-timeline { position: relative; display: flex; flex-direction: column; gap: 15px; padding-left: 24px; }
.atx-timeline::before {
    content: "";
    position: absolute;
    top: 10px;
    bottom: 10px;
    left: 5px;
    width: 2px;
    border-radius: 999px;
    background: linear-gradient(var(--sun-coral, #ef7b52), rgba(239, 123, 82, .08));
}
.atx-timeline-item { position: relative; display: grid; grid-template-columns: 1fr; }
.atx-timeline-marker { position: absolute; top: 28px; left: -24px; width: 12px; height: 12px; }
.atx-timeline-marker span {
    display: block;
    width: 12px;
    height: 12px;
    border: 3px solid var(--card-bg);
    border-radius: 50%;
    background: var(--sun-coral, #ef7b52);
    box-shadow: 0 0 0 4px rgba(239, 123, 82, .14);
}
.atx-timeline-card {
    width: 100%;
    padding: 21px 23px !important;
    border-radius: 19px !important;
}
[data-theme="sunrise"] .atx-timeline-card {
    border-left: 1px solid rgba(255, 255, 255, .95) !important;
    background: linear-gradient(135deg, rgba(255, 255, 255, .94), rgba(255, 249, 239, .9)) !important;
}
.atx-timeline-card:hover { transform: translateX(4px) !important; border-color: var(--card-hover-border) !important; box-shadow: var(--card-hover-shadow) !important; }
.atx-card-top { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.atx-repeat-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border: 1px solid var(--card-border);
    border-radius: 999px;
    color: var(--icon-color);
    background: rgba(255, 255, 255, .55);
    font-size: .68rem;
    font-weight: 900;
}
.atx-card-actions { display: flex; align-items: center; gap: 6px; }
.atx-card-actions a {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border: 1px solid var(--card-border);
    border-radius: 9px;
    color: var(--btn-secondary-text) !important;
    background: rgba(255, 255, 255, .45);
    text-decoration: none;
}
.atx-card-actions a:hover { color: var(--icon-color) !important; background: #fff !important; }
.atx-card-actions a:last-child:hover { color: #c43d35 !important; }
.atx-timeline-card .reminder-content {
    margin: 13px 0 16px !important;
    color: var(--sun-ink, #463329) !important;
    font-size: 1.16rem !important;
    font-weight: 700 !important;
    line-height: 1.55 !important;
}
.atx-card-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; padding-top: 13px; border-top: 1px dashed var(--card-border); }
.atx-card-foot .reminder-meta,
.atx-card-foot .reminder-email { color: var(--footer-color) !important; font-size: .7rem !important; }
.atx-card-foot .reminder-status { margin-left: auto; padding: 3px 10px; border: 1px solid var(--status-border); border-radius: 999px; color: var(--status-color) !important; background: var(--status-bg); font-size: .66rem !important; font-weight: 900; }
.atx-empty {
    position: relative;
    padding: 62px 24px;
    overflow: hidden;
    border: 1px dashed var(--card-border);
    border-radius: 24px;
    background: rgba(255, 255, 255, .46);
    text-align: center;
}
.atx-empty::before { content: "☀"; position: absolute; right: 30px; top: 6px; color: rgba(239, 123, 82, .1); font-size: 7rem; line-height: 1; }
.atx-empty-icon { width: 58px; height: 58px; display: grid; place-items: center; margin: 0 auto 13px; border-radius: 18px; color: var(--sun-coral, #ef7b52); background: rgba(239, 123, 82, .09); font-size: 1.4rem; }
.atx-empty h3 { margin: 0 0 6px; color: var(--icon-color); font-size: 1.05rem; font-weight: 900; }
.atx-empty p { margin: 0; color: var(--footer-color); font-size: .76rem; }
.atx-content > div[style*="display:flex"][style*="justify-content:center"] > .card-form { border-radius: 22px !important; }

@media (max-width: 1040px) {
    .atx-topbar { grid-template-columns: auto 1fr; gap: 10px; padding: 10px 18px; }
    .atx-account { grid-column: 2; justify-self: end; }
    .atx-nav { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; overflow-x: auto; padding-bottom: 4px; }
}

@media (max-width: 720px) {
    .atx-topbar { position: relative; align-items: start; padding: 12px 14px; }
    .atx-brand-copy small { display: none; }
    .atx-user { display: none; }
    .atx-account { grid-column: 2; }
    .atx-account .theme-selector { max-width: 150px; }
    .atx-ribbon { padding: 6px 15px; }
    .atx-ribbon-copy { display: none; }
    .container.atx-workspace { padding: 18px 14px; }
    .atx-plan-head { align-items: flex-start; flex-direction: column; }
    .atx-create-btn { width: 100%; justify-content: center; }
    .atx-timeline { padding-left: 18px; }
    .atx-timeline::before { left: 2px; }
    .atx-timeline-marker { left: -21px; }
    .atx-timeline-card { padding: 17px !important; }
    .atx-card-foot { align-items: flex-start; flex-direction: column; gap: 6px; }
    .atx-card-foot .reminder-status { margin-left: 0; }
}


/* 超级管理员可配置的全站公告 */
.site-announcement {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 0 18px;
    padding: 11px 15px;
    border: 1px solid var(--card-border);
    border-left: 4px solid var(--icon-color);
    border-radius: 12px;
    background: var(--card-bg);
    color: var(--btn-secondary-text);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .06);
    font-size: .82rem;
    font-weight: 700;
    line-height: 1.55;
}
.site-announcement i { flex: 0 0 auto; color: var(--icon-color); }
.site-announcement span { min-width: 0; word-break: break-word; }
[data-theme="neon"] .site-announcement { border-color: rgba(69,224,255,.2); border-left-color: #45e0ff; background: rgba(9,23,42,.88); color: #c9eaff; }
[data-theme="candy"] .site-announcement { border-color: rgba(255,255,255,.95); border-left-color: #ff6f91; background: rgba(255,255,255,.8); color: #5a4a72; }
[data-theme="sunrise"] .site-announcement { border-color: #f0dfca; border-left-color: #ef7b52; background: rgba(255,253,248,.88); color: #765846; }
