@import url('https://fonts.googleapis.com/css2?family=Gowun+Dodum&family=Inter:wght@400;500;600;700;800&family=Noto+Sans+KR:wght@400;500;600;700;800&display=swap');

:root{color-scheme:light;--bg:#f7f9fc;--surface:#fff;--ink:#111827;--muted:#657186;--line:#dbe3ed;--blue:#246bfd;--navy:#21364e;--shadow:0 16px 40px rgba(37,55,80,.08);font-family:Inter,"Noto Sans KR",sans-serif;scroll-behavior:smooth}
*{box-sizing:border-box}html{scroll-padding-top:84px}body{margin:0;background:var(--bg);color:var(--ink);font-size:16px;line-height:1.6;transition:background .3s,color .3s}a{color:inherit;text-decoration:none}button,input{font:inherit}button{cursor:pointer}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.skip-link{position:fixed;z-index:1000;top:-80px;left:1rem;padding:.75rem 1rem;background:#111827;color:#fff;border-radius:.5rem}.skip-link:focus{top:1rem}.site-header{height:78px;background:rgba(255,255,255,.94);border-bottom:1px solid var(--line);position:relative;z-index:100}.nav-wrap{height:100%;max-width:1440px;margin:auto;padding:0 3.3rem;display:flex;align-items:center;gap:2.4rem}.brand{display:flex;align-items:baseline;white-space:nowrap;margin-right:auto}.brand strong{font-size:2rem;letter-spacing:-.08em;line-height:1}.brand>span{color:#7f8ca0;font-size:.78rem;margin-left:.15rem}.brand small{font-size:.68rem;color:#7f8ca0;font-weight:400;margin-left:.85rem}.main-nav{display:flex;align-self:stretch;gap:2rem}.main-nav a{font-size:.9rem;display:flex;align-items:center;position:relative}.main-nav a:after{content:"";position:absolute;left:0;right:0;bottom:0;height:2px;background:var(--blue);transform:scaleX(0);transition:transform .2s}.main-nav a:hover:after,.main-nav a.active:after{transform:scaleX(1)}.main-nav a.active{color:var(--blue)}.nav-actions{display:flex;align-items:center;gap:1rem;margin-left:1rem}.icon-button,.theme-button,.menu-button{border:0;background:none;color:inherit}.icon-button{width:40px;height:40px;display:grid;place-items:center}.icon-button svg{width:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}.theme-button{display:flex;align-items:center;gap:.55rem;border:1px solid var(--line);padding:.55rem .85rem;border-radius:999px;background:var(--surface)}.theme-button b{font-size:.75rem;font-weight:600}.menu-button{display:none;width:42px;padding:8px}.menu-button>span{display:block;height:2px;background:currentColor;margin:6px 0}
.hero{height:min(540px,calc(100vh - 78px));min-height:440px;position:relative;overflow:hidden;color:#fff}.hero-image,.hero-shade{position:absolute;inset:0}.hero-image{background:url('../images/hero-lake.png') center 52%/cover no-repeat;transform:scale(1.01)}.hero-shade{background:linear-gradient(90deg,rgba(2,14,25,.82) 0%,rgba(5,21,34,.63) 39%,rgba(12,27,43,.05) 72%),linear-gradient(0deg,rgba(0,8,16,.25),transparent 42%)}.hero-content{position:relative;z-index:1;max-width:1440px;margin:auto;padding:3.2rem 3.8rem}.hero-kicker{font-size:.92rem;margin:0 0 .5rem}.hero h1{font-size:clamp(3.6rem,6.5vw,6.2rem);line-height:1;letter-spacing:-.065em;margin:0;text-shadow:0 3px 18px rgba(0,0,0,.18)}.hero h1 span{font-size:.47em;color:#c9dcf1;letter-spacing:-.035em;margin-left:.22rem}.hero-en{font-size:1.35rem;letter-spacing:.025em;margin:.4rem 0 1.1rem}.hero-copy{font-size:1.15rem;font-weight:500;line-height:1.8;margin:0}.hero-line{display:block;width:42px;height:1px;background:rgba(255,255,255,.85);margin:1.25rem 0}.hero-note{font-size:1rem;margin:0;line-height:1.8}.hero-script{position:absolute;z-index:2;right:8.5%;top:10%;font:1.45rem/1.7 "Gowun Dodum",cursive;transform:rotate(-4deg);color:#172337;text-align:center}.scroll-cue{position:absolute;z-index:2;bottom:1rem;left:50%;transform:translateX(-50%);font-size:.6rem;letter-spacing:.2em;display:flex;align-items:center;gap:.6rem}.scroll-cue i{display:block;width:22px;height:1px;background:#fff}
.home-content{max-width:1440px;margin:auto;padding:1.4rem 2rem 3rem}.daily-quote{margin:0 0 1.4rem;padding:1.35rem 2.2rem;border:1px solid #e2e8f1;border-radius:14px;background:linear-gradient(90deg,#f0f5fd,#fbfcff);text-align:center;font-size:1.2rem;font-weight:500;position:relative}.daily-quote span{font-size:1.8rem;font-weight:700}.daily-quote cite{font-size:.85rem;font-style:normal;position:absolute;right:2rem;bottom:1rem}.bento-grid{display:grid;grid-template-columns:repeat(6,1fr);gap:1rem}.card,.mini-card{border:1px solid rgba(208,218,230,.95);border-radius:14px;position:relative;overflow:hidden;box-shadow:0 3px 12px rgba(35,52,75,.03)}.card{padding:1.7rem 1.8rem;min-height:300px;background:var(--surface)}.note-card,.tools-card{grid-column:span 3}.links-card,.archive-card,.projects-card{grid-column:span 2;min-height:265px}.statement-card{grid-column:span 4;min-height:270px}.about-card{grid-column:span 2;min-height:270px}.card-heading{display:flex;align-items:flex-start;gap:.9rem;position:relative;z-index:2}.card-heading h2{font-size:1.35rem;line-height:1.2;margin:0 0 .25rem}.card-heading p{font-size:.78rem;margin:0;color:#343d4b}.card-icon{display:grid;place-items:center;min-width:38px;height:38px;font-size:1.8rem;line-height:1;color:#8fa4ba}.blue{color:#3f83f8}.green{color:#3eaa79}.gold{color:#b98a49}.purple{color:#7657dc}.slate{color:#6b7b8d}.card ul{font-size:.84rem;padding-left:1.1rem;line-height:1.8;margin:1rem 0}.pill-link{position:absolute;left:1.8rem;bottom:1.35rem;border:1px solid var(--blue);color:#1859d8;padding:.46rem 1rem;border-radius:999px;font-size:.78rem;font-weight:600;z-index:3;transition:.2s}.pill-link:hover{background:var(--blue);color:#fff;transform:translateY(-2px)}.pill-link span{margin-left:.25rem}.note-card{background:linear-gradient(110deg,#fff 45%,#e8f0f8)}.note-visual{position:absolute;right:1.4rem;bottom:3.2rem;width:105px;height:105px;background:linear-gradient(150deg,#edf3f8,#c8d1d9);border-radius:52% 48% 42% 58%;display:grid;place-items:center;text-align:center;font-size:.82rem;line-height:1.4;box-shadow:0 12px 25px rgba(69,83,98,.18);transform:rotate(-4deg)}.tools-card{background:linear-gradient(140deg,#354d67,#1d3147);color:#fff}.inverse p{color:#d8e1ea}.tool-list{width:65%;display:grid;grid-template-columns:repeat(3,1fr);gap:.55rem;margin:1rem 0}.tool-list>span{min-height:73px;background:#f9fbff;color:#162235;border-radius:9px;display:flex;flex-direction:column;align-items:center;justify-content:center;font-size:.7rem;font-weight:600}.tool-list b{color:#3979e3;font-size:1.35rem;line-height:1}.tool-list small{font-size:.58rem;font-weight:400}.pill-link.light{border-color:#fff;background:#fff;color:#264b70}.pill-link.light:hover{background:#dfeaf5}.tools-motto{position:absolute;right:1.8rem;top:40%;font:1rem/1.8 "Gowun Dodum",cursive;text-align:center;color:#e0e9f3}.links-card{background:linear-gradient(135deg,#f3fff8,#e5f7ef)}.archive-card{background:linear-gradient(135deg,#fffdf9,#f6eee2)}.projects-card{background:linear-gradient(135deg,#fbfaff,#eeeaff)}.green-link{border-color:#3e9f72;color:#257653}.gold-link{border-color:#b78b50;color:#8d642f}.purple-link{border-color:#7657dc;color:#6040c8}.big-symbol{position:absolute;right:1.4rem;bottom:3.2rem;font-size:3.8rem;opacity:.8}.green-text{color:#3b9d70}.gold-text{color:#b78a4f}.purple-text{color:#7657dc}.statement-card{background:linear-gradient(110deg,rgba(3,15,28,.96),rgba(14,42,70,.84)),url('../images/hero-lake.png') center 18%/cover;color:#fff;display:flex;justify-content:space-between;align-items:center}.statement-card h2{font-size:1.55rem;line-height:1.5;margin:0}.statement-card span{display:block;width:40px;height:1px;background:#fff;margin:1rem 0}.statement-card p{font-size:.9rem}.statement-card>p{line-height:2.1;color:#c8d6e6;letter-spacing:.07em}.about-card{background:linear-gradient(135deg,#fff,#edf5fd)}.about-card>p{font-size:.82rem;line-height:1.8;margin:1.2rem 0 3rem}.mini-grid{display:grid;grid-template-columns:1.15fr .9fr 1fr;gap:1rem;margin-top:1rem}.mini-card{min-height:165px;background:var(--surface);padding:1.1rem 1.3rem}.mini-card h3{font-size:.95rem;margin:0 0 .8rem}.mini-card h3 span{color:#3580f2}.mini-card>a{position:absolute;right:1.3rem;top:1.1rem;font-size:.7rem}.mini-card dl{font-size:.76rem;margin:0}.mini-card dl div{display:flex;gap:1rem;margin:.4rem 0}.mini-card dt{color:#7a8798}.mini-card dd{margin:0}.mini-card>p{background:#f2f7fd;border-radius:9px;padding:1rem;margin:.5rem 0;text-align:center;font-size:.82rem}.mini-card time{position:absolute;right:1.3rem;top:1.2rem;font-size:.68rem;color:#7c8796}.mini-card p strong{font-size:.92rem}
.site-footer{background:linear-gradient(180deg,#f0f4f9,#f8fafc);border-top:1px solid var(--line);padding:1.5rem 3rem 1rem}.footer-main,.footer-bottom{max-width:1376px;margin:auto;display:flex;align-items:center}.footer-main{gap:1rem;padding-bottom:1rem}.footer-brand{font-size:1.65rem;font-weight:800;letter-spacing:-.07em}.footer-brand span{font-size:.65rem;color:#7c8999}.footer-main small{font-size:.65rem;color:#7c8999}.footer-main nav{display:flex;gap:1.2rem;margin:auto;font-size:.75rem}.footer-main em{font:italic .82rem "Gowun Dodum",cursive;color:#69768a}.to-top{width:36px;height:36px;border-radius:50%;display:grid;place-items:center;background:#637287;color:#fff;margin-left:1.2rem}.footer-bottom{border-top:1px solid var(--line);padding-top:.8rem;justify-content:space-between;font-size:.65rem;color:#8490a0}.search-panel[hidden]{display:none}.search-panel{position:fixed;inset:0;z-index:500;display:grid;place-items:start center;padding-top:14vh}.search-backdrop{position:absolute;inset:0;border:0;background:rgba(4,15,27,.65);backdrop-filter:blur(5px)}.search-box{position:relative;width:min(620px,calc(100% - 2rem));padding:1.6rem;background:var(--surface);color:var(--ink);border-radius:16px;box-shadow:var(--shadow)}.search-box label{display:block;font-size:1.25rem;font-weight:700;margin-bottom:1rem}.search-box div{display:flex}.search-box input{width:100%;border:1px solid var(--line);padding:.9rem 1rem;border-radius:9px 0 0 9px;background:var(--bg);color:inherit}.search-box button{border:0;background:var(--blue);color:#fff;padding:0 1.5rem;border-radius:0 9px 9px 0}.search-box p{font-size:.75rem;color:var(--muted);margin:.7rem 0 0}.no-scroll{overflow:hidden}.dark{--bg:#101722;--surface:#172131;--ink:#eef4fb;--muted:#9eacbd;--line:#2b3a4e;color-scheme:dark}.dark .site-header{background:rgba(23,33,49,.95)}.dark .daily-quote{background:linear-gradient(90deg,#19263a,#172131)}.dark .card-heading p,.dark .about-card>p{color:#c2cfdd}.dark .note-card,.dark .about-card{background:linear-gradient(135deg,#172131,#202f43)}.dark .links-card{background:#183129}.dark .archive-card{background:#30281e}.dark .projects-card{background:#29243a}.dark .mini-card>p{background:#202e41}.dark .site-footer{background:#121b28}
@media(max-width:1050px){.nav-wrap{padding:0 1.5rem;gap:1rem}.brand small{display:none}.main-nav{gap:1.1rem}.main-nav a{font-size:.78rem}.theme-button b{display:none}.hero-content{padding-left:2.5rem}.note-card,.tools-card{grid-column:span 6}.links-card,.archive-card,.projects-card{grid-column:span 2}.statement-card{grid-column:span 4}.about-card{grid-column:span 2}}
@media(max-width:760px){html{scroll-padding-top:64px}.site-header{height:64px;position:sticky;top:0}.nav-wrap{padding:0 1rem}.brand strong{font-size:1.7rem}.menu-button{display:block;order:3}.nav-actions{margin-left:0}.theme-button{display:none}.main-nav{display:none;position:absolute;top:64px;left:0;right:0;height:auto;background:var(--surface);padding:.7rem 1rem 1rem;box-shadow:0 15px 20px rgba(20,35,55,.14);align-items:stretch;gap:0}.main-nav.open{display:grid;grid-template-columns:repeat(2,1fr)}.main-nav a{padding:.8rem}.main-nav a:after{display:none}.hero{height:600px;min-height:0}.hero-image{background-position:88% center}.hero-shade{background:linear-gradient(90deg,rgba(2,14,25,.87),rgba(5,21,34,.35)),linear-gradient(0deg,rgba(0,8,16,.35),transparent)}.hero-content{padding:4.3rem 1.4rem}.hero-kicker{font-size:.8rem}.hero h1{font-size:3.5rem}.hero-en{font-size:1.05rem}.hero-copy{font-size:1rem}.hero-note{font-size:.88rem}.hero-script{right:6%;top:5%;font-size:1rem}.home-content{padding:1rem}.daily-quote{padding:1.2rem 1rem 2.4rem;font-size:1rem}.daily-quote cite{bottom:.55rem}.bento-grid{display:block}.card{margin-bottom:1rem}.links-card,.archive-card,.projects-card,.statement-card,.about-card{min-height:280px}.tool-list{width:100%}.tools-motto{display:none}.statement-card h2{font-size:1.25rem}.mini-grid{grid-template-columns:1fr}.site-footer{padding:1.5rem 1rem}.footer-main{flex-wrap:wrap}.footer-main nav{order:3;width:100%;justify-content:space-between;gap:.4rem;overflow-x:auto}.footer-main em{margin-left:auto}.footer-bottom{gap:1rem;align-items:flex-start}.footer-bottom span:last-child{text-align:right}}
@media(max-width:430px){.hero{height:560px}.hero-content{padding-top:3.7rem}.hero h1{font-size:3rem}.hero-copy br,.hero-note br{display:none}.card{padding:1.4rem}.note-visual,.big-symbol{opacity:.38}.pill-link{left:1.4rem}.tool-list>span{min-height:66px}.footer-main em{display:none}}
@media(prefers-reduced-motion:reduce){:root{scroll-behavior:auto}*{transition:none!important}}

.tool-list>a{min-height:73px;background:#f9fbff;color:#162235;border-radius:9px;display:flex;flex-direction:column;align-items:center;justify-content:center;font-size:.7rem;font-weight:600;transition:transform .2s,box-shadow .2s}.tool-list>a:hover{transform:translateY(-3px);box-shadow:0 8px 16px rgba(0,0,0,.18)}

/* Tools */
.subpage-main{max-width:1240px;margin:0 auto;padding:3.5rem 2rem 5rem}.page-intro{min-height:220px;border-radius:22px;padding:3rem 3.2rem;color:#fff;background:linear-gradient(120deg,#172a41,#315574);display:flex;align-items:center;justify-content:space-between;overflow:hidden;position:relative}.page-intro:after{content:"";position:absolute;width:330px;height:330px;border:70px solid rgba(255,255,255,.06);border-radius:50%;right:-70px;top:-120px}.page-intro h1{font-size:clamp(2rem,4vw,3.2rem);line-height:1.25;margin:.2rem 0 .7rem}.page-intro p{margin:0;color:#dce8f3}.page-intro>span{font-size:5rem;font-weight:800;letter-spacing:-.06em;color:rgba(255,255,255,.09);z-index:1}.eyebrow{font-size:.72rem!important;letter-spacing:.18em;font-weight:700;color:#3976e8!important;margin:0!important}.tools-directory{margin-top:3rem}.section-heading{display:flex;align-items:end;justify-content:space-between;border-bottom:1px solid var(--line);padding-bottom:1rem;margin-bottom:1.3rem}.section-heading p,.result-heading p{font-size:.66rem;letter-spacing:.16em;color:#3976e8;font-weight:700;margin:0}.section-heading h2{font-size:1.5rem;margin:.15rem 0 0}.section-heading small{color:var(--muted)}.directory-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:1rem}.directory-card{min-height:250px;border:1px solid var(--line);border-radius:18px;padding:1.8rem;background:var(--surface);position:relative;transition:transform .2s,box-shadow .2s}.directory-card.ready:hover{transform:translateY(-4px);box-shadow:var(--shadow)}.directory-icon{width:52px;height:52px;display:grid;place-items:center;border-radius:14px;background:#eaf2ff;color:#2d6fe7;font-size:1.7rem}.status-badge{position:absolute;right:1.6rem;top:1.6rem;font-size:.7rem;padding:.3rem .65rem;border-radius:999px;background:#e6f7ef;color:#20805b}.directory-card h3{font-size:1.25rem;margin:1.2rem 0 .4rem}.directory-card p{font-size:.85rem;color:var(--muted);max-width:430px;margin:0}.directory-card strong{position:absolute;left:1.8rem;bottom:1.6rem;color:#2366dc;font-size:.82rem}.coming-soon{background:linear-gradient(135deg,var(--surface),#f4f1ff)}.coming-soon .directory-icon{background:#eee9ff;color:#7455d9}.coming-soon .status-badge{background:#eee9ff;color:#6746ca}.coming-soon strong{color:var(--muted)}

/* Stock return calculator */
.breadcrumb{font-size:.75rem;color:var(--muted);display:flex;gap:.55rem;align-items:center;margin-bottom:2rem}.breadcrumb strong{color:var(--ink)}.calculator-heading{display:flex;align-items:center;gap:1.2rem;margin-bottom:2rem}.calculator-title-icon{width:62px;height:62px;display:grid;place-items:center;border-radius:17px;background:linear-gradient(135deg,#e7f0ff,#f3f7ff);color:#286ce4;font-size:2rem}.calculator-heading h1{font-size:clamp(1.8rem,4vw,2.6rem);line-height:1.2;margin:.2rem 0 .4rem}.calculator-heading>div>p:last-child{margin:0;color:var(--muted);font-size:.9rem}.calculator-shell{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(320px,.75fr);gap:1.2rem;align-items:start}.calculator-form,.calculator-results{background:var(--surface);border:1px solid var(--line);border-radius:20px;box-shadow:0 10px 30px rgba(38,59,86,.05)}.calculator-form{padding:2rem}.form-section+.form-section{border-top:1px solid var(--line);margin-top:2rem;padding-top:2rem}.form-section-title{display:flex;gap:.9rem;align-items:flex-start;margin-bottom:1.3rem}.form-section-title>span{width:34px;height:34px;display:grid;place-items:center;border-radius:10px;background:#eaf2ff;color:#2769df;font-size:.7rem;font-weight:800}.form-section-title h2{font-size:1.1rem;margin:0}.form-section-title p{font-size:.72rem;color:var(--muted);margin:.1rem 0 0}.field-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem}.field-grid label>span:first-child{display:block;font-size:.78rem;font-weight:600;margin-bottom:.45rem}.field-grid label small{font-weight:400;color:var(--muted)}.input-wrap{display:flex;border:1px solid var(--line);border-radius:10px;background:var(--bg);transition:border-color .2s,box-shadow .2s}.input-wrap:focus-within{border-color:#3477eb;box-shadow:0 0 0 3px rgba(52,119,235,.12)}.input-wrap input{width:100%;min-width:0;border:0;background:transparent;color:var(--ink);padding:.8rem .9rem;outline:0;text-align:right}.input-wrap b{display:flex;align-items:center;padding:0 .85rem 0 0;color:var(--muted);font-size:.75rem;white-space:nowrap}.form-message{min-height:1.5rem;color:#d23b4e;font-size:.78rem;margin:1rem 0 0}.calculator-actions{display:flex;gap:.7rem}.calculator-actions button{border-radius:10px;padding:.85rem 1.3rem;font-weight:700;font-size:.85rem}.calculate-button{flex:1;border:1px solid #246bfd;background:#246bfd;color:#fff}.calculate-button:hover{background:#1556cf}.reset-button{border:1px solid var(--line);background:var(--surface);color:var(--muted)}.calculator-results{padding:1.6rem;position:sticky;top:1rem}.result-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:1rem}.result-heading h2{font-size:1.25rem;margin:.1rem 0 0}.result-heading>span{font-size:.7rem;padding:.3rem .65rem;border-radius:999px;background:var(--bg);color:var(--muted)}.primary-result{border-radius:15px;padding:1.4rem;text-align:center;background:#f2f6fb;transition:background .2s}.primary-result small{display:block;color:var(--muted);font-size:.72rem}.primary-result strong{display:block;font-size:2rem;line-height:1.3;margin:.25rem 0}.primary-result>span{font-size:.82rem;font-weight:700}.primary-result.positive{background:#eaf8f1;color:#10845b}.primary-result.negative{background:#fff0f2;color:#d23950}.primary-result.neutral{color:var(--ink)}.result-list{margin:1.2rem 0 0}.result-list>div{display:flex;justify-content:space-between;gap:1rem;padding:.55rem .2rem;font-size:.78rem}.result-list dt{color:var(--muted)}.result-list dd{margin:0;font-weight:600}.result-list .total-cost{border-top:1px dashed var(--line);border-bottom:1px dashed var(--line);padding:.75rem .2rem;margin:.2rem 0}.result-note{font-size:.67rem;line-height:1.55;color:var(--muted);background:var(--bg);padding:.8rem;border-radius:9px;margin:1rem 0 0}.back-to-tools{display:inline-flex;align-items:center;gap:.45rem;margin-top:1.7rem;color:var(--muted);font-size:.8rem}.back-to-tools:hover{color:#246bfd}.dark .page-intro{background:linear-gradient(120deg,#14283e,#253f5a)}.dark .directory-card.coming-soon{background:linear-gradient(135deg,#172131,#27233a)}.dark .directory-icon,.dark .calculator-title-icon,.dark .form-section-title>span{background:#243854}.dark .primary-result.neutral{background:#202d40}.dark .primary-result.positive{background:#17392e}.dark .primary-result.negative{background:#42232b}

@media(max-width:900px){.calculator-shell{grid-template-columns:1fr}.calculator-results{position:static}.page-intro>span{font-size:3.5rem}.field-grid{grid-template-columns:1fr 1fr}.field-grid label:last-child{grid-column:span 2}}
@media(max-width:760px){.subpage-main{padding:1.5rem 1rem 3rem}.page-intro{min-height:200px;padding:2rem}.page-intro>span{display:none}.directory-grid{grid-template-columns:1fr}.calculator-heading{align-items:flex-start}.calculator-title-icon{width:50px;height:50px;min-width:50px}.calculator-heading>div>p:last-child{font-size:.8rem}.calculator-form{padding:1.25rem}.field-grid{grid-template-columns:1fr}.field-grid label:last-child{grid-column:auto}.calculator-actions{flex-direction:column}.reset-button{order:2}.calculator-results{padding:1.25rem}.primary-result strong{font-size:1.75rem}}

.preset-section{padding-bottom:2rem;border-bottom:1px solid var(--line);margin-bottom:2rem}.preset-grid select{width:100%;border:1px solid var(--line);border-radius:10px;background:var(--bg);color:var(--ink);padding:.8rem .9rem;outline:0}.preset-grid select:focus{border-color:#3477eb;box-shadow:0 0 0 3px rgba(52,119,235,.12)}.preset-summary{display:flex;justify-content:space-between;gap:1rem;margin:1rem 0 0;padding:.8rem 1rem;border-radius:10px;background:#edf5ff;color:#245a9e;font-size:.76rem}.fee-guide{margin-top:2.5rem}.guide-table-wrap{overflow-x:auto;border:1px solid var(--line);border-radius:14px;background:var(--surface)}.guide-table-wrap table{width:100%;min-width:680px;border-collapse:collapse;font-size:.8rem}.guide-table-wrap th,.guide-table-wrap td{padding:.9rem 1rem;text-align:center;border-bottom:1px solid var(--line)}.guide-table-wrap th{background:var(--bg);color:var(--muted);font-size:.72rem}.guide-table-wrap tr:last-child td{border-bottom:0}.guide-notes{display:grid;grid-template-columns:repeat(3,1fr);gap:.8rem;margin-top:1rem}.guide-notes p{margin:0;padding:1rem;border:1px solid var(--line);border-radius:12px;background:var(--surface);font-size:.73rem;color:var(--muted)}.guide-notes strong{display:block;color:var(--ink);margin-bottom:.25rem}.guide-source{text-align:right;color:var(--muted);font-size:.68rem}.guide-source a{color:#246bfd;text-decoration:underline}.dark .preset-summary{background:#203650;color:#9fc6ff}@media(max-width:760px){.preset-summary{display:block}.preset-summary span{display:block;margin-top:.25rem}.guide-notes{grid-template-columns:1fr}.fee-guide .section-heading{align-items:flex-start}.fee-guide .section-heading small{white-space:nowrap}}

/* Keep the working calculator controls within a desktop screen */
.calculator-page{padding-top:1.35rem}.calculator-page .breadcrumb{margin-bottom:.65rem}.calculator-page .calculator-heading{margin-bottom:1rem}.calculator-page .calculator-title-icon{width:50px;height:50px;border-radius:14px;font-size:1.6rem}.calculator-page .calculator-heading h1{font-size:2rem;margin:.1rem 0}.calculator-page .calculator-form{padding:1.15rem 1.35rem}.calculator-page .form-section-title{margin-bottom:.7rem;gap:.65rem}.calculator-page .form-section-title>span{width:29px;height:29px;border-radius:8px}.calculator-page .form-section-title h2{font-size:1rem}.calculator-page .form-section+.form-section{margin-top:1rem;padding-top:1rem}.calculator-page .preset-section{padding-bottom:1rem;margin-bottom:1rem}.calculator-page .preset-grid select,.calculator-page .input-wrap input{padding:.58rem .75rem}.calculator-page .preset-summary{margin-top:.65rem;padding:.55rem .8rem}.calculator-page .field-grid label>span:first-child{margin-bottom:.25rem}.calculator-page .form-message{min-height:1.1rem;margin:.45rem 0 0}.calculator-page .calculator-actions button{padding:.65rem 1.1rem}.calculator-page .calculator-results{padding:1.15rem}.calculator-page .result-heading{margin-bottom:.65rem}.calculator-page .primary-result{padding:.85rem}.calculator-page .primary-result strong{font-size:1.65rem}.calculator-page .result-list{margin:.65rem 0 0}.calculator-page .result-list>div{padding:.34rem .2rem}.calculator-page .result-list .total-cost{padding:.5rem .2rem}.calculator-page .result-note{margin-top:.65rem;padding:.6rem}.calculator-page .fee-guide{margin-top:1.8rem}
@media(max-width:760px){.calculator-page{padding-top:1rem}.calculator-page .calculator-heading h1{font-size:1.6rem}.calculator-page .calculator-heading{gap:.8rem}.calculator-page .calculator-form{padding:1rem}.calculator-page .form-section-title p{line-height:1.45}.calculator-page .preset-summary{font-size:.7rem}}

/* Date calculator */
.purple-tool,.date-icon{color:#7054d5!important;background:#eeeaff!important}.date-page{padding-top:1.35rem}.date-page .breadcrumb{margin-bottom:.65rem}.date-page .calculator-heading{margin-bottom:1.2rem}.date-page .calculator-title-icon{width:50px;height:50px;border-radius:14px;font-size:1.5rem}.date-page .calculator-heading h1{font-size:2rem;margin:.1rem 0}.date-calculator-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem}.date-tool-card{border:1px solid var(--line);border-radius:18px;background:var(--surface);padding:1.25rem;box-shadow:0 10px 30px rgba(38,59,86,.05)}.date-card-heading{display:flex;gap:.7rem;align-items:flex-start;padding-bottom:.9rem;border-bottom:1px solid var(--line)}.date-card-heading>span{width:30px;height:30px;display:grid;place-items:center;border-radius:8px;background:#eaf2ff;color:#2769df;font-size:.68rem;font-weight:800}.date-tool-card:nth-child(2) .date-card-heading>span{background:#eeeaff;color:#6d50ce}.date-card-heading h2{font-size:1.05rem;margin:0}.date-card-heading p{font-size:.7rem;color:var(--muted);margin:.05rem 0 0}.date-fields{display:grid;grid-template-columns:1fr auto 1fr;align-items:end;gap:.6rem;margin-top:1rem}.date-fields label>span,.offset-fields label>span:first-child{display:block;font-size:.75rem;font-weight:600;margin-bottom:.3rem}.date-fields input,.offset-fields input,.offset-fields select{width:100%;height:42px;border:1px solid var(--line);border-radius:9px;background:var(--bg);color:var(--ink);padding:.55rem .7rem;outline:0}.date-fields input:focus,.offset-fields input:focus,.offset-fields select:focus{border-color:#3477eb;box-shadow:0 0 0 3px rgba(52,119,235,.12)}.date-arrow{height:42px;display:grid;place-items:center;color:var(--muted)}.offset-fields{display:grid;grid-template-columns:1.25fr .7fr .8fr;gap:.6rem;margin-top:1rem}.days-input{display:flex;height:42px;border:1px solid var(--line);border-radius:9px;background:var(--bg)}.days-input input{height:40px;border:0;text-align:right}.days-input b{display:flex;align-items:center;padding-right:.7rem;font-size:.73rem;color:var(--muted)}.check-option{display:flex;align-items:center;gap:.45rem;margin:.75rem 0;font-size:.72rem;color:var(--muted)}.check-option input{accent-color:#246bfd}.date-calculate-button{width:100%;border:0;border-radius:9px;background:#246bfd;color:#fff;padding:.65rem;font-weight:700;font-size:.8rem}.date-calculate-button:hover{background:#1556cf}.purple-button{background:#7054d5}.purple-button:hover{background:#5a3fc0}.date-message{height:1rem;margin:.25rem 0;color:#d23b4e;font-size:.7rem}.date-result{background:#edf5ff;border-radius:13px;padding:1rem;text-align:center;color:#245a9e}.date-result>small{display:block;font-size:.68rem}.date-result>strong{display:block;font-size:1.55rem;line-height:1.4;margin:.1rem 0}.date-result>p{font-size:.76rem;margin:0 0 .6rem}.date-result dl{margin:0;padding-top:.5rem;border-top:1px solid rgba(36,90,158,.15)}.date-result dl>div{display:flex;justify-content:space-between;gap:1rem;padding:.22rem 0;font-size:.68rem}.date-result dt{color:var(--muted)}.date-result dd{margin:0;font-weight:600;text-align:right}.purple-result{background:#f1eeff;color:#6043bd}.date-help{margin-top:1.2rem;border:1px solid var(--line);border-radius:15px;background:var(--surface);padding:1rem 1.2rem}.date-help h2{font-size:.9rem;margin:0 0 .7rem}.date-help>div{display:grid;grid-template-columns:repeat(3,1fr);gap:.7rem}.date-help p{font-size:.7rem;color:var(--muted);margin:0}.date-help strong{display:block;color:var(--ink);margin-bottom:.15rem}.dark .purple-tool,.dark .date-icon{background:#30294d!important}.dark .date-result{background:#203650}.dark .purple-result{background:#30294d}.dark .date-card-heading>span{background:#243854}.dark .date-tool-card:nth-child(2) .date-card-heading>span{background:#30294d}
@media(max-width:900px){.date-calculator-grid{grid-template-columns:1fr}.date-help>div{grid-template-columns:1fr}}
@media(max-width:760px){.date-page{padding-top:1rem}.date-page .calculator-heading{gap:.8rem}.date-page .calculator-heading h1{font-size:1.6rem}.date-tool-card{padding:1rem}.date-fields{grid-template-columns:1fr}.date-arrow{display:none}.offset-fields{grid-template-columns:1fr 1fr}.offset-fields label:first-child{grid-column:span 2}.date-result>strong{font-size:1.35rem}}

.lunar-converter{margin-top:1.2rem;border:1px solid var(--line);border-radius:18px;background:var(--surface);padding:1.25rem;box-shadow:0 10px 30px rgba(38,59,86,.05)}.lunar-heading{display:flex;align-items:center;gap:.8rem}.lunar-heading>span{width:44px;height:44px;display:grid;place-items:center;border-radius:12px;background:#eeeaff;color:#7054d5;font-size:1.7rem}.lunar-heading h2{font-size:1.1rem;margin:.05rem 0}.lunar-heading div>p:last-child{font-size:.7rem;color:var(--muted);margin:0}.lunar-heading>small{margin-left:auto;color:var(--muted);font-size:.68rem}.lunar-tabs{display:flex;border-bottom:1px solid var(--line);margin-top:1rem}.lunar-tabs button{border:0;border-bottom:2px solid transparent;background:transparent;color:var(--muted);padding:.65rem 1rem;font-size:.76rem;font-weight:700}.lunar-tabs button.active{color:#6545ca;border-bottom-color:#7054d5}.lunar-body{display:grid;grid-template-columns:1.3fr .9fr;gap:1rem;align-items:stretch;margin-top:1rem}.lunar-panel{display:flex;align-items:end;gap:.65rem}.lunar-panel[hidden]{display:none}.lunar-panel>label{flex:1}.lunar-panel label>span,.lunar-inputs label>span{display:block;font-size:.72rem;font-weight:600;margin-bottom:.25rem}.lunar-panel input{width:100%;height:42px;border:1px solid var(--line);border-radius:9px;background:var(--bg);color:var(--ink);padding:.55rem .7rem;outline:0}.lunar-panel>button{height:42px;border:0;border-radius:9px;background:#7054d5;color:#fff;padding:0 1.2rem;font-size:.76rem;font-weight:700;white-space:nowrap}.lunar-inputs{flex:1;display:grid;grid-template-columns:1.2fr .75fr .75fr auto;gap:.5rem;align-items:end}.lunar-inputs .leap-option{height:42px;display:flex;align-items:center;gap:.3rem;padding:.5rem}.lunar-inputs .leap-option span{margin:0;white-space:nowrap}.lunar-result{min-height:92px;border-radius:12px;background:#f1eeff;color:#6043bd;padding:1rem;text-align:center;display:flex;flex-direction:column;justify-content:center}.lunar-result small{font-size:.67rem}.lunar-result strong{font-size:1.15rem;margin:.15rem 0}.lunar-result p{font-size:.68rem;margin:0;color:var(--muted)}.lunar-message{min-height:1rem;margin:.35rem 0 0;color:#d23b4e;font-size:.7rem}.lunar-source{text-align:right;color:var(--muted);font-size:.65rem;margin:.2rem 0 0}.dark .lunar-heading>span,.dark .lunar-result{background:#30294d}
@media(max-width:900px){.lunar-body{grid-template-columns:1fr}.lunar-panel{align-items:stretch;flex-direction:column}.lunar-panel>button{width:100%}}
@media(max-width:760px){.lunar-heading{align-items:flex-start}.lunar-heading>small{display:none}.lunar-tabs button{flex:1}.lunar-inputs{grid-template-columns:repeat(3,1fr)}.lunar-inputs .leap-option{grid-column:span 3}.lunar-source{text-align:left}}
.leap-option:has(input:disabled){opacity:.48}.leap-help{margin:.35rem 0 0;color:var(--muted);font-size:.66rem}.lunar-panel#lunar-panel{flex-wrap:wrap}.lunar-panel#lunar-panel>button{order:1}.lunar-panel#lunar-panel .leap-help{flex-basis:100%;order:2}

.calendar-bottom-grid{display:grid;grid-template-columns:1fr 1fr;gap:1rem;align-items:start}.calendar-bottom-grid .lunar-converter{margin-top:1.2rem}.calendar-bottom-grid .lunar-body{grid-template-columns:1fr}.annual-calendar{margin-top:1.2rem;border:1px solid var(--line);border-radius:18px;background:var(--surface);padding:1.25rem;box-shadow:0 10px 30px rgba(38,59,86,.05)}.annual-heading{display:flex;align-items:end;gap:1rem;padding-bottom:.8rem;border-bottom:1px solid var(--line)}.annual-heading h2{font-size:1.1rem;margin:.05rem 0}.annual-heading div>p:last-child{font-size:.7rem;color:var(--muted);margin:0}.annual-heading label{margin-left:auto}.annual-heading label>span{display:block;font-size:.65rem;font-weight:600;margin-bottom:.2rem}.annual-heading input{width:92px;height:38px;border:1px solid var(--line);border-radius:9px;background:var(--bg);color:var(--ink);padding:.4rem .55rem;text-align:center}.annual-list{display:grid;grid-template-columns:1fr 1fr;gap:0 .8rem;margin-top:.65rem}.annual-item{display:flex;align-items:center;justify-content:space-between;gap:.6rem;padding:.52rem .25rem;border-bottom:1px solid var(--line)}.annual-item>span{display:flex;align-items:baseline;gap:.35rem}.annual-item strong{font-size:.76rem}.annual-item small{font-size:.6rem;color:var(--muted)}.annual-item time{font-size:.72rem;font-weight:600;white-space:nowrap}.annual-item.past{opacity:.48}.annual-item.today{color:#246bfd;background:#edf5ff;border-radius:7px;padding-left:.45rem;padding-right:.45rem}.annual-note{font-size:.64rem;color:var(--muted);margin:.7rem 0 0}.annual-error{grid-column:span 2;color:#d23b4e;font-size:.72rem}.dark .annual-item.today{background:#203650}
@media(max-width:1050px){.calendar-bottom-grid{grid-template-columns:1fr}.calendar-bottom-grid .lunar-body{grid-template-columns:1.3fr .9fr}}
@media(max-width:760px){.calendar-bottom-grid .lunar-body{grid-template-columns:1fr}.annual-heading{align-items:flex-start}.annual-list{grid-template-columns:1fr}.annual-error{grid-column:auto}}

/* Age calculator */
.age-tool-icon,.age-title-icon{color:#ec6b7c!important;background:#fff0f3!important}.age-page{padding-top:1.35rem}.age-page .breadcrumb{margin-bottom:.65rem}.age-page .calculator-heading{margin-bottom:1.2rem}.age-page .calculator-title-icon{width:50px;height:50px;border-radius:14px;font-size:1.5rem}.age-page .calculator-heading h1{font-size:2rem;margin:.1rem 0}.age-shell{display:grid;grid-template-columns:1.1fr 1.4fr;gap:1rem}.age-form,.age-results,.age-details{border:1px solid var(--line);border-radius:18px;background:var(--surface);box-shadow:0 10px 30px rgba(38,59,86,.05)}.age-form{padding:1.25rem}.age-form-heading{display:flex;justify-content:space-between;align-items:center;font-size:.82rem;font-weight:700;margin-bottom:1rem}.age-form-heading button{border:1px solid var(--line);border-radius:999px;background:var(--bg);color:var(--muted);padding:.35rem .7rem;font-size:.67rem}.age-fields{display:grid;grid-template-columns:1fr auto 1fr;gap:.7rem;align-items:end}.age-fields>span{height:42px;display:grid;place-items:center;color:var(--muted)}.age-fields label>span{display:block;font-size:.72rem;font-weight:600;margin-bottom:.25rem}.age-fields input{width:100%;height:42px;border:1px solid var(--line);border-radius:9px;background:var(--bg);color:var(--ink);padding:.55rem .7rem}.age-message{height:1.1rem;margin:.35rem 0;color:#d23b4e;font-size:.7rem}.age-submit{width:100%;border:0;border-radius:9px;background:#ef7181;color:#fff;padding:.68rem;font-weight:700;font-size:.8rem}.age-submit:hover{background:#da586b}.age-results{display:grid;grid-template-columns:1.25fr 1fr 1fr;gap:.7rem;padding:1rem}.age-result-card{border-radius:13px;background:var(--bg);padding:1rem;display:flex;flex-direction:column;justify-content:center;text-align:center;position:relative}.age-result-card>span{position:absolute;top:.55rem;right:.55rem;border-radius:999px;background:#fff;color:#df5367;padding:.2rem .45rem;font-size:.58rem;font-weight:700}.age-result-card small{font-size:.68rem;color:var(--muted)}.age-result-card strong{font-size:1.65rem;margin:.1rem 0}.age-result-card p{font-size:.64rem;color:var(--muted);margin:0}.age-result-card.main-age{background:linear-gradient(135deg,#fff0f3,#fff7f8);color:#c94056}.age-details{margin-top:1rem;padding:1.25rem}.age-detail-summary{display:grid;grid-template-columns:repeat(4,1fr);border-bottom:1px solid var(--line);padding-bottom:1rem}.age-detail-summary>div{text-align:center;border-right:1px solid var(--line)}.age-detail-summary>div:last-child{border:0}.age-detail-summary span{display:block;font-size:.66rem;color:var(--muted)}.age-detail-summary strong{font-size:.95rem}.age-explanation{display:grid;grid-template-columns:repeat(3,1fr);gap:.8rem;margin-top:1rem}.age-explanation article{padding:.9rem;border-radius:12px;background:var(--bg)}.age-explanation article>span{font-size:.62rem;color:#e0586c;font-weight:700}.age-explanation h2{font-size:.82rem;margin:.15rem 0 .35rem}.age-explanation p{font-size:.68rem;color:var(--muted);margin:0}.age-source{text-align:right;font-size:.64rem;color:var(--muted);margin:.8rem 0 0}.age-source a{color:#246bfd;text-decoration:underline}.dark .age-tool-icon,.dark .age-title-icon{background:#482832!important}.dark .age-result-card.main-age{background:#432731}.dark .age-result-card>span{background:#5a3240}
@media(max-width:900px){.age-shell{grid-template-columns:1fr}.age-detail-summary{grid-template-columns:1fr 1fr;gap:.7rem}.age-detail-summary>div{border-right:0}.age-explanation{grid-template-columns:1fr}}
@media(max-width:760px){.age-page{padding-top:1rem}.age-page .calculator-heading{gap:.8rem}.age-page .calculator-heading h1{font-size:1.6rem}.age-fields{grid-template-columns:1fr}.age-fields>span{display:none}.age-results{grid-template-columns:1fr 1fr}.age-result-card.main-age{grid-column:span 2}.age-detail-summary{grid-template-columns:1fr 1fr}.age-source{text-align:left}}

.birth-type-tabs{display:flex;margin-bottom:.8rem;border-radius:9px;background:var(--bg);padding:.2rem}.birth-type-tabs button{flex:1;border:0;border-radius:7px;background:transparent;color:var(--muted);padding:.42rem;font-size:.72rem;font-weight:700}.birth-type-tabs button.active{background:var(--surface);color:#df5367;box-shadow:0 2px 8px rgba(34,52,74,.08)}.birth-input-panel[hidden]{display:none}.birth-input-panel>label{display:block}.lunar-birth-panel>div{display:grid;grid-template-columns:1.4fr .75fr .75fr;gap:.35rem}.lunar-birth-panel input{min-width:0}.birth-leap-option{display:flex!important;align-items:center;gap:.3rem;margin-top:.35rem;font-size:.65rem;color:var(--muted)}.birth-leap-option input{width:auto;height:auto}.birth-leap-option:has(input:disabled){opacity:.48}.birth-calendar-help{font-size:.65rem;color:var(--muted);margin:.45rem 0 0}.age-detail-summary{grid-template-columns:repeat(5,1fr)}
@media(max-width:900px){.age-detail-summary{grid-template-columns:repeat(3,1fr)}}@media(max-width:760px){.age-detail-summary{grid-template-columns:1fr 1fr}.lunar-birth-panel>div{grid-template-columns:1.4fr .75fr .75fr}}
+

/* Stock average calculator */
.stock-average-icon,.average-title-icon{color:#2e9c78!important;background:#e9f8f2!important}.average-page{padding-top:1.35rem}.average-page .breadcrumb{margin-bottom:.65rem}.average-page .calculator-heading{margin-bottom:.8rem}.average-page .calculator-title-icon{width:50px;height:50px;border-radius:14px;font-size:1.6rem}.average-page .calculator-heading h1{font-size:2rem;margin:.1rem 0}.stock-tool-switch{display:flex;gap:.4rem;margin:0 0 1rem;padding:.25rem;border-radius:10px;background:#eaf0f6;width:max-content}.stock-tool-switch a{padding:.45rem .9rem;border-radius:8px;color:var(--muted);font-size:.72rem;font-weight:700}.stock-tool-switch a.active{background:var(--surface);color:#246bfd;box-shadow:0 2px 8px rgba(33,53,78,.09)}.average-shell{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(300px,.65fr);gap:1rem;align-items:start}.average-form,.average-results{border:1px solid var(--line);border-radius:18px;background:var(--surface);box-shadow:0 10px 30px rgba(38,59,86,.05)}.average-form{padding:1.25rem}.average-form-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:1rem}.average-form-heading h2{font-size:1.05rem;margin:0}.average-form-heading p{font-size:.7rem;color:var(--muted);margin:0}.average-form-heading button{border:1px solid #2e9c78;border-radius:999px;background:#fff;color:#20815f;padding:.4rem .75rem;font-size:.7rem;font-weight:700}.purchase-table-head,.purchase-row{display:grid;grid-template-columns:48px 1fr .8fr 1fr 32px;gap:.6rem;align-items:center}.purchase-table-head{padding:0 .4rem .4rem;color:var(--muted);font-size:.66rem;text-align:center}.purchase-row{padding:.55rem .4rem;border-top:1px solid var(--line)}.purchase-number{font-size:.72rem;font-weight:700;color:#278466;text-align:center}.average-input,.fee-input{display:flex;border:1px solid var(--line);border-radius:9px;background:var(--bg)}.average-input:focus-within,.fee-input:focus-within{border-color:#2e9c78;box-shadow:0 0 0 3px rgba(46,156,120,.1)}.average-input input,.fee-input input{width:100%;min-width:0;border:0;outline:0;background:transparent;color:var(--ink);padding:.55rem;text-align:right}.average-input b,.fee-input b{display:flex;align-items:center;padding-right:.55rem;color:var(--muted);font-size:.68rem}.row-amount{text-align:right;font-size:.75rem}.remove-purchase{width:28px;height:28px;border:0;border-radius:50%;background:var(--bg);color:var(--muted);font-size:1rem}.remove-purchase:hover:not(:disabled){background:#fff0f2;color:#d23b4e}.remove-purchase:disabled{opacity:.3;cursor:default}.mobile-label{display:none}.average-options{display:flex;align-items:end;gap:.8rem;border-top:1px solid var(--line);margin-top:.5rem;padding-top:.8rem}.average-options label{width:180px}.average-options label>span:first-child{display:block;font-size:.7rem;font-weight:600;margin-bottom:.25rem}.average-options p{font-size:.65rem;color:var(--muted);margin:0 0 .55rem}.average-message{height:1rem;color:#d23b4e;font-size:.68rem;margin:.25rem 0}.average-actions{display:flex;gap:.6rem}.average-actions button{border-radius:9px;padding:.65rem 1rem;font-size:.76rem;font-weight:700}.average-submit{flex:1;border:0;background:#2e9c78;color:#fff}.average-submit:hover{background:#247f63}.average-actions #average-reset{border:1px solid var(--line);background:var(--surface);color:var(--muted)}.average-results{padding:1.15rem;position:sticky;top:1rem}.average-primary{text-align:center;border-radius:13px;background:#eaf8f3;color:#207c60;padding:1.2rem}.average-primary small{display:block;font-size:.68rem}.average-primary strong{display:block;font-size:1.8rem;line-height:1.35}.average-primary p{font-size:.65rem;margin:0;color:var(--muted)}.average-results dl{margin:.8rem 0}.average-results dl>div{display:flex;justify-content:space-between;padding:.45rem .15rem;font-size:.73rem}.average-results dt{color:var(--muted)}.average-results dd{margin:0;font-weight:700}.average-results .average-total{border-top:1px dashed var(--line);margin-top:.2rem;padding-top:.7rem}.average-results>p{font-size:.64rem;color:var(--muted);background:var(--bg);border-radius:8px;padding:.65rem;margin:0}.average-example{display:flex;align-items:center;justify-content:center;gap:1rem;margin-top:1rem;border:1px solid var(--line);border-radius:13px;background:var(--surface);padding:.8rem;font-size:.72rem}.average-example strong{color:#20815f}.average-example b{color:var(--muted)}.dark .stock-tool-switch{background:#111b28}.dark .stock-average-icon,.dark .average-title-icon{background:#18382e!important}.dark .average-primary{background:#18382e}.dark .average-form-heading button{background:#172131}
@media(max-width:900px){.average-shell{grid-template-columns:1fr}.average-results{position:static}}
@media(max-width:760px){.average-page{padding-top:1rem}.average-page .calculator-heading{gap:.8rem}.average-page .calculator-heading h1{font-size:1.55rem}.stock-tool-switch{width:100%}.stock-tool-switch a{flex:1;text-align:center}.purchase-table-head{display:none}.purchase-row{grid-template-columns:42px 1fr 1fr 28px}.purchase-row .row-amount{grid-column:2/4;text-align:right}.mobile-label{display:block;font-size:.62rem;color:var(--muted);margin-bottom:.2rem}.average-options{align-items:stretch;flex-direction:column}.average-options label{width:100%}.average-options p{margin:0}.average-actions{flex-direction:column}.average-example{flex-wrap:wrap;gap:.5rem}}

.average-mode-tabs{display:grid;grid-template-columns:1fr 1fr;max-width:420px;margin:0 0 .7rem;border:1px solid var(--line);border-radius:11px;background:var(--surface);padding:.25rem}.average-mode-tabs button{border:0;border-radius:8px;background:transparent;color:var(--muted);padding:.55rem;font-size:.76rem;font-weight:700}.average-mode-tabs button.active{background:#2e9c78;color:#fff;box-shadow:0 3px 10px rgba(46,156,120,.2)}.average-options label[hidden],.average-results dl>div[hidden]{display:none}.average-options:has(#sell-tax-option:not([hidden])) label{width:145px}.average-options:has(#sell-tax-option:not([hidden])) p{flex:1}.dark .average-mode-tabs{background:#172131}
@media(max-width:760px){.average-mode-tabs{max-width:none}.average-options:has(#sell-tax-option:not([hidden])) label{width:100%}}

/* Unified stock trades */
.trade-groups{display:grid;grid-template-columns:1fr 1fr;gap:.8rem}.trade-group{min-width:0;border:1px solid var(--line);border-radius:13px;padding:.8rem;background:var(--bg)}.trade-group-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:.65rem}.trade-group-heading>div{display:flex;align-items:center;gap:.5rem}.trade-group-heading b{width:26px;height:26px;display:grid;place-items:center;border-radius:7px;background:#eaf2ff;color:#2769df;font-size:.62rem}.sell-group .trade-group-heading b{background:#e9f8f2;color:#248361}.trade-group-heading span{display:flex;flex-direction:column}.trade-group-heading strong{font-size:.82rem}.trade-group-heading small{font-size:.58rem;color:var(--muted)}.trade-group-heading button{border:1px solid #3477eb;border-radius:999px;background:var(--surface);color:#2466d5;padding:.3rem .55rem;font-size:.61rem;font-weight:700}.sell-group .trade-group-heading button{border-color:#2e9c78;color:#20815f}.trade-row-head,.trade-row{display:grid;grid-template-columns:33px 1fr .7fr .8fr 24px;gap:.35rem;align-items:center}.trade-row-head{padding:0 .15rem .25rem;text-align:center;font-size:.56rem;color:var(--muted)}.trade-row{border-top:1px solid var(--line);padding:.4rem .15rem}.trade-number{text-align:center;font-size:.61rem;font-weight:700;color:#3477eb}.sell-group .trade-number{color:#2e9c78}.trade-row label small{display:none}.trade-row .input-wrap input{padding:.42rem .35rem;font-size:.7rem}.trade-row .input-wrap b{padding-right:.35rem;font-size:.58rem}.trade-amount{text-align:right;font-size:.65rem;white-space:nowrap}.remove-trade{width:23px;height:23px;border:0;border-radius:50%;background:var(--surface);color:var(--muted);line-height:1}.remove-trade:disabled{opacity:.3}.trade-summary{display:flex;justify-content:space-between;margin-top:.4rem;padding-top:.45rem;border-top:1px dashed var(--line);font-size:.62rem;color:var(--muted)}.trade-summary strong{color:var(--ink)}.calculator-page .trade-groups+.form-section{margin-top:1rem;padding-top:1rem}
@media(max-width:1050px){.trade-groups{grid-template-columns:1fr}.trade-row-head,.trade-row{grid-template-columns:40px 1fr .8fr 1fr 25px}}
@media(max-width:760px){.trade-row-head{display:none}.trade-row{grid-template-columns:32px 1fr 1fr 23px}.trade-row label small{display:block;font-size:.56rem;color:var(--muted);margin-bottom:.15rem}.trade-row .trade-amount{grid-column:2/4}.trade-group-heading{align-items:flex-start}.trade-group-heading small{max-width:190px}}

/* Discount calculator */
.discount-tool-icon,.discount-title-icon{color:#e78322!important;background:#fff3e4!important}.discount-page{padding-top:1.35rem}.discount-page .breadcrumb{margin-bottom:.65rem}.discount-page .calculator-heading{margin-bottom:1.2rem}.discount-page .calculator-title-icon{width:50px;height:50px;border-radius:14px;font-size:1.5rem}.discount-page .calculator-heading h1{font-size:2rem;margin:.1rem 0}.discount-shell{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(300px,.7fr);gap:1rem;align-items:start}.discount-form,.discount-results{border:1px solid var(--line);border-radius:18px;background:var(--surface);box-shadow:0 10px 30px rgba(38,59,86,.05)}.discount-form{padding:1.35rem}.discount-basic{display:grid;grid-template-columns:1.4fr 1fr;gap:1rem}.discount-form label>span:first-child{display:block;font-size:.75rem;font-weight:700;margin-bottom:.3rem}.discount-input{display:flex;border:1px solid var(--line);border-radius:10px;background:var(--bg)}.discount-input:focus-within{border-color:#ed922f;box-shadow:0 0 0 3px rgba(237,146,47,.12)}.discount-input input{width:100%;min-width:0;border:0;outline:0;background:transparent;color:var(--ink);padding:.75rem .8rem;text-align:right}.discount-input b{display:flex;align-items:center;padding-right:.75rem;color:var(--muted);font-size:.72rem}.quick-rates{display:flex;align-items:center;gap:.4rem;margin:.8rem 0}.quick-rates>span{font-size:.65rem;color:var(--muted);margin-right:.2rem}.quick-rates button{border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--muted);padding:.3rem .65rem;font-size:.65rem;font-weight:700}.quick-rates button:hover{border-color:#ed922f;color:#d87517;background:#fff8ef}.discount-extra{border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:.8rem 0}.discount-extra summary{display:flex;justify-content:space-between;align-items:center;cursor:pointer;list-style:none;font-size:.74rem;font-weight:700;color:#d87517}.discount-extra summary::-webkit-details-marker{display:none}.discount-extra[open] summary span{transform:rotate(45deg)}.discount-extra summary span{font-size:1rem;transition:.2s}.discount-extra>div{display:grid;grid-template-columns:repeat(3,1fr);gap:.7rem;margin-top:.8rem}.discount-extra label small{display:block;color:var(--muted);font-size:.58rem;margin-top:.25rem}.discount-message{height:1rem;margin:.3rem 0;color:#d23b4e;font-size:.68rem}.discount-actions{display:flex;gap:.6rem}.discount-actions button{border-radius:9px;padding:.68rem 1rem;font-size:.76rem;font-weight:700}.discount-submit{flex:1;border:0;background:#ed922f;color:#fff}.discount-submit:hover{background:#d77b1b}.discount-actions button:last-child{border:1px solid var(--line);background:var(--surface);color:var(--muted)}.discount-results{padding:1.15rem;position:sticky;top:1rem}.discount-primary{text-align:center;border-radius:13px;background:#fff3e4;color:#cf7015;padding:1.2rem}.discount-primary small{display:block;font-size:.68rem}.discount-primary strong{display:block;font-size:1.85rem;line-height:1.35}.discount-primary p{font-size:.65rem;margin:0;color:var(--muted)}.discount-results dl{margin:.75rem 0}.discount-results dl>div{display:flex;justify-content:space-between;padding:.4rem .15rem;font-size:.72rem}.discount-results dt{color:var(--muted)}.discount-results dd{margin:0;font-weight:700}.discount-results .discount-total-saving{border-top:1px dashed var(--line);margin-top:.2rem;padding-top:.65rem;color:#d87517}.discount-meter{height:7px;border-radius:999px;background:var(--bg);overflow:hidden}.discount-meter span{display:block;width:0;height:100%;border-radius:inherit;background:linear-gradient(90deg,#ffb152,#ed7d22);transition:width .25s}.discount-results>p{font-size:.62rem;color:var(--muted);margin:.6rem 0 0}.discount-example{display:flex;align-items:center;justify-content:center;gap:.8rem;margin-top:1rem;border:1px solid var(--line);border-radius:13px;background:var(--surface);padding:.8rem;font-size:.72rem}.discount-example strong{color:#d87517}.discount-example b{border-radius:999px;background:#fff3e4;color:#d87517;padding:.25rem .55rem}.discount-example em{font-style:normal;font-weight:800}.dark .discount-tool-icon,.dark .discount-title-icon,.dark .discount-primary{background:#422d1b!important}.dark .quick-rates button:hover{background:#422d1b}
@media(max-width:900px){.discount-shell{grid-template-columns:1fr}.discount-results{position:static}}
@media(max-width:760px){.discount-page{padding-top:1rem}.discount-page .calculator-heading{gap:.8rem}.discount-page .calculator-heading h1{font-size:1.6rem}.discount-basic,.discount-extra>div{grid-template-columns:1fr}.quick-rates{flex-wrap:wrap}.quick-rates>span{width:100%}.discount-actions{flex-direction:column}.discount-example{flex-wrap:wrap}}

/* Unit converter */
.unit-tool-icon,.unit-title-icon{color:#2d82bb!important;background:#e8f5fc!important}.unit-page{padding-top:1.35rem}.unit-page .breadcrumb{margin-bottom:.65rem}.unit-page .calculator-heading{margin-bottom:1.2rem}.unit-page .calculator-title-icon{width:50px;height:50px;border-radius:14px;font-size:1.5rem}.unit-page .calculator-heading h1{font-size:2rem;margin:.1rem 0}.unit-shell{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(300px,.65fr);gap:1rem;align-items:start}.unit-form,.unit-reference{border:1px solid var(--line);border-radius:18px;background:var(--surface);box-shadow:0 10px 30px rgba(38,59,86,.05)}.unit-form{padding:1.25rem}.unit-category-tabs{display:grid;grid-template-columns:repeat(7,1fr);gap:.3rem;padding:.25rem;background:var(--bg);border-radius:11px}.unit-category-tabs button{border:0;border-radius:8px;background:transparent;color:var(--muted);padding:.48rem .25rem;font-size:.67rem;font-weight:700}.unit-category-tabs button.active{background:#2d82bb;color:#fff;box-shadow:0 3px 10px rgba(45,130,187,.2)}.unit-conversion{display:grid;grid-template-columns:1fr 44px 1fr;gap:.7rem;align-items:center;margin-top:1.1rem}.unit-side>span:first-child{display:block;font-size:.7rem;font-weight:700;margin-bottom:.3rem}.unit-value-wrap,.unit-side output{height:70px;display:flex;align-items:center;border:1px solid var(--line);border-radius:11px;background:var(--bg);padding:0 1rem}.unit-value-wrap input{width:100%;border:0;outline:0;background:transparent;color:var(--ink);font-size:1.6rem;font-weight:700;text-align:right}.unit-side output{justify-content:flex-end;color:#2477ae;font-size:1.6rem;font-weight:800;overflow:hidden}.unit-side select{width:100%;margin-top:.5rem;border:1px solid var(--line);border-radius:9px;background:var(--surface);color:var(--ink);padding:.55rem}.unit-swap{width:42px;height:42px;border:1px solid #9bcbe7;border-radius:50%;background:#e8f5fc;color:#2477ae;font-size:1.1rem;margin-top:1.3rem}.unit-swap:hover{transform:rotate(180deg);transition:.25s}.unit-equation{text-align:center;border-radius:9px;background:#eaf6fc;color:#2477ae;padding:.65rem;margin:.9rem 0;font-size:.76rem;font-weight:700}.unit-actions{display:flex;gap:.5rem}.unit-actions button{flex:1;border:1px solid #2d82bb;border-radius:9px;background:#2d82bb;color:#fff;padding:.62rem;font-size:.72rem;font-weight:700}.unit-actions button:last-child{border-color:var(--line);background:var(--surface);color:var(--muted)}.unit-message{height:1rem;text-align:center;color:#248361;font-size:.65rem;margin:.25rem 0 0}.unit-reference{padding:1.15rem}.unit-reference-heading{display:flex;justify-content:space-between;align-items:center}.unit-reference-heading p{font-size:.6rem;letter-spacing:.15em;color:#2d82bb;font-weight:700;margin:0}.unit-reference-heading h2{font-size:1.05rem;margin:.1rem 0}.unit-reference-heading>span{width:36px;height:36px;display:grid;place-items:center;border-radius:10px;background:#e8f5fc;color:#2d82bb}.unit-reference>p{font-size:.65rem;color:var(--muted);margin:.3rem 0 .6rem}.unit-reference dl{margin:0}.unit-reference dl>div{display:flex;justify-content:space-between;align-items:center;border-top:1px solid var(--line);padding:.55rem .1rem;font-size:.7rem}.unit-reference dt{color:var(--muted)}.unit-reference dt small{font-size:.58rem}.unit-reference dd{margin:0;font-weight:700}.unit-tip{display:flex;gap:.8rem;align-items:center;margin-top:1rem;border:1px solid #cfe7f5;border-radius:13px;background:#f0f9fe;padding:.8rem 1rem;font-size:.7rem}.unit-tip strong{color:#2477ae;white-space:nowrap}.unit-tip p{margin:0;color:var(--muted)}.dark .unit-tool-icon,.dark .unit-title-icon,.dark .unit-reference-heading>span,.dark .unit-equation,.dark .unit-swap{background:#1b3547!important}.dark .unit-tip{background:#172c3a}
@media(max-width:900px){.unit-shell{grid-template-columns:1fr}}
@media(max-width:760px){.unit-page{padding-top:1rem}.unit-page .calculator-heading{gap:.8rem}.unit-page .calculator-heading h1{font-size:1.6rem}.unit-category-tabs{grid-template-columns:repeat(4,1fr)}.unit-conversion{grid-template-columns:1fr}.unit-swap{margin:0 auto;transform:rotate(90deg)}.unit-swap:hover{transform:rotate(270deg)}.unit-side output,.unit-value-wrap{height:60px}.unit-tip{align-items:flex-start}}

/* Keep the tools button clear of the second tool row. */
.tools-card .pill-link{position:relative;display:inline-flex;align-items:center;left:auto;bottom:auto;margin-top:.35rem}

/* MSJ wordmark */
.brand-logo{display:block;width:150px;height:auto}.brand{align-items:center}.hero h1{width:min(500px,72vw);height:auto}.hero-logo{display:block;width:100%;height:auto;filter:drop-shadow(0 5px 16px rgba(0,0,0,.25))}.footer-brand{display:flex;align-items:center}.footer-logo{display:block;width:135px;height:auto}.dark .brand-logo,.dark .footer-logo{filter:brightness(0) invert(1) opacity(.92)}
@media(max-width:1050px){.brand-logo{width:138px}}@media(max-width:760px){.brand-logo{width:124px}.hero h1{width:min(390px,88vw)}.footer-logo{width:120px}}

/* Readability */
html{font-size:17px}.main-nav a{font-size:.92rem}.brand small{font-size:.73rem}.theme-button b{font-size:.78rem}
.hero-kicker{font-size:1rem}.hero-en{font-size:1.42rem}.hero-copy{font-size:1.2rem}.hero-note{font-size:1.05rem}
.card-heading p{font-size:.86rem}.card ul{font-size:.9rem}.pill-link{font-size:.82rem}.tool-list>span,.tool-list>a{font-size:.76rem}.tool-list small{font-size:.64rem}.about-card>p{font-size:.87rem}.statement-card p{font-size:.94rem}.mini-card h3{font-size:1rem}.mini-card>a{font-size:.76rem}.mini-card dl{font-size:.82rem}.mini-card>p{font-size:.87rem}.mini-card time{font-size:.73rem}
.footer-main small,.footer-main nav{font-size:.73rem}.footer-main em{font-size:.88rem}.footer-bottom{font-size:.7rem}
.breadcrumb{font-size:.82rem}.calculator-heading>div>p:last-child{font-size:.94rem}.page-intro p{font-size:1rem}.section-heading small{font-size:.78rem}.directory-card p{font-size:.91rem}.directory-card strong{font-size:.87rem}.status-badge{font-size:.74rem}
.form-section-title p{font-size:.78rem}.field-grid label>span:first-child{font-size:.83rem}.preset-summary{font-size:.78rem}.form-message{font-size:.8rem}.calculator-actions button{font-size:.88rem}.result-heading>span{font-size:.75rem}.primary-result small{font-size:.78rem}.primary-result>span{font-size:.88rem}.result-list>div{font-size:.83rem}.result-note{font-size:.74rem}.fee-guide table{font-size:.78rem}.guide-notes p,.guide-source{font-size:.74rem}
.trade-group-heading strong{font-size:.88rem}.trade-group-heading small{font-size:.66rem}.trade-group-heading button{font-size:.68rem}.trade-row-head{font-size:.64rem}.trade-number,.trade-amount{font-size:.7rem}.trade-summary{font-size:.69rem}
.date-card-heading p,.lunar-heading div>p:last-child,.annual-heading div>p:last-child{font-size:.76rem}.date-fields label>span,.offset-fields label>span:first-child{font-size:.8rem}.check-option{font-size:.77rem}.date-calculate-button{font-size:.84rem}.date-message{font-size:.75rem}.date-result>small{font-size:.74rem}.date-result>p{font-size:.82rem}.date-result dl>div{font-size:.75rem}.date-help p{font-size:.76rem}.lunar-panel label>span,.lunar-inputs label>span{font-size:.78rem}.lunar-tabs button{font-size:.82rem}.lunar-result small,.lunar-result p,.lunar-source,.leap-help{font-size:.72rem}.annual-heading label>span,.annual-note{font-size:.71rem}.annual-item strong{font-size:.82rem}.annual-item small{font-size:.67rem}.annual-item time{font-size:.78rem}
.age-form-heading{font-size:.88rem}.age-form-heading button{font-size:.73rem}.age-fields label>span{font-size:.79rem}.age-message{font-size:.75rem}.age-submit{font-size:.85rem}.age-result-card small{font-size:.74rem}.age-result-card p{font-size:.7rem}.age-result-card>span{font-size:.65rem}.age-detail-summary span{font-size:.72rem}.age-explanation article>span{font-size:.69rem}.age-explanation h2{font-size:.88rem}.age-explanation p,.age-source,.birth-calendar-help,.birth-leap-option{font-size:.74rem}
.discount-form label>span:first-child{font-size:.82rem}.quick-rates>span,.quick-rates button{font-size:.72rem}.discount-extra summary{font-size:.82rem}.discount-extra label small{font-size:.67rem}.discount-message{font-size:.74rem}.discount-actions button{font-size:.82rem}.discount-primary small{font-size:.75rem}.discount-primary p{font-size:.72rem}.discount-results dl>div{font-size:.79rem}.discount-results>p{font-size:.7rem}.discount-example{font-size:.79rem}
.unit-category-tabs button{font-size:.74rem}.unit-side>span:first-child{font-size:.78rem}.unit-side select{font-size:.82rem}.unit-equation{font-size:.82rem}.unit-actions button{font-size:.79rem}.unit-message{font-size:.72rem}.unit-reference-heading p{font-size:.67rem}.unit-reference>p{font-size:.72rem}.unit-reference dl>div{font-size:.78rem}.unit-reference dt small{font-size:.66rem}.unit-tip{font-size:.77rem}
@media(max-width:760px){html{font-size:16.5px}.hero-kicker{font-size:.88rem}.hero-copy{font-size:1.04rem}.hero-note{font-size:.94rem}.calculator-heading>div>p:last-child{font-size:.85rem}.tool-list>span,.tool-list>a{min-height:72px;font-size:.78rem}.tool-list small{font-size:.66rem}.trade-row label small{font-size:.64rem}.footer-main nav{font-size:.76rem}}

/* Contact */
.footer-identity{display:flex;align-items:center;gap:1rem}.footer-email{font-size:.73rem;color:#596a80;text-decoration:underline;text-underline-offset:3px}.contact-modal{width:min(620px,calc(100% - 2rem));max-height:calc(100vh - 2rem);overflow:auto;border:0;border-radius:18px;padding:2rem;background:linear-gradient(135deg,#f8faff,#edf4ff);color:#172334;box-shadow:0 28px 80px rgba(7,25,48,.32)}.contact-modal::backdrop{background:rgba(5,17,32,.68);backdrop-filter:blur(5px)}.contact-modal[open]{animation:contact-in .2s ease-out}.contact-close{position:absolute;right:1rem;top:.8rem;border:0;background:transparent;color:#64748b;font-size:1.8rem;line-height:1;cursor:pointer}.contact-kicker{margin:0 0 .35rem;color:var(--blue);font-size:.76rem;font-weight:800;letter-spacing:.14em}.contact-intro h2{margin:0 0 .55rem;font-size:1.55rem}.contact-intro>p:last-child{margin:0 0 1.25rem;color:#536174;line-height:1.65;font-size:.9rem}.contact-form{display:grid;grid-template-columns:1fr 1fr;gap:.85rem}.contact-form label{display:grid;gap:.4rem;color:#344258;font-size:.82rem;font-weight:700}.contact-form input,.contact-form textarea{width:100%;border:1px solid #cbd6e4;border-radius:9px;padding:.78rem .9rem;background:#fff;color:#172334;font:inherit;outline:none}.contact-form input:focus,.contact-form textarea:focus{border-color:#3979ef;box-shadow:0 0 0 3px rgba(57,121,239,.12)}.contact-message{grid-column:1/-1}.contact-form textarea{resize:vertical;min-height:120px}.contact-form button{grid-column:1/-1;justify-self:end;border:0;border-radius:999px;padding:.75rem 1.3rem;background:#2169e8;color:#fff;font-family:inherit;font-size:.86rem;font-weight:700;cursor:pointer}.contact-form button span{margin-left:.45rem}.contact-honey{position:absolute!important;left:-9999px!important}.contact-alert{margin:0 0 1rem;padding:.75rem 1rem;border-radius:9px;font-weight:700}.contact-alert.success{background:#e4f7ef;color:#087852}.contact-alert.error{background:#fff0f0;color:#b42318}.dark .contact-modal{background:linear-gradient(135deg,#172131,#1c2b41);color:#eef4fb}.dark .contact-intro>p:last-child,.dark .contact-form label{color:#c4d0df}.dark .contact-form input,.dark .contact-form textarea{background:#101a28;border-color:#3b4c62;color:#eef4fb}@keyframes contact-in{from{opacity:0;transform:translateY(12px) scale(.98)}to{opacity:1;transform:none}}
@media(max-width:760px){.footer-identity{flex-wrap:wrap;gap:.35rem 1rem}.footer-email{width:100%}.contact-modal{padding:1.4rem}.contact-form{grid-template-columns:1fr}.contact-message{grid-column:auto}.contact-form button{width:100%;justify-self:stretch}.contact-intro>p:last-child br{display:none}}
.contact-alert{transition:opacity .45s ease,transform .45s ease}.contact-alert.fade-out{opacity:0;transform:translateY(-5px)}

/* Archive */
.archive-page,.archive-editor-page{max-width:1320px}.archive-hero{min-height:300px;border-radius:24px;padding:3.1rem 3.4rem;background:linear-gradient(120deg,rgba(43,31,17,.95),rgba(145,102,46,.78)),url('../images/hero-lake.png') center 57%/cover;color:#fff;display:flex;align-items:center;justify-content:space-between;gap:2rem}.archive-hero h1{font-size:clamp(2rem,4vw,3.3rem);line-height:1.25;margin:.3rem 0 .8rem}.archive-hero p:last-child{max-width:610px;color:#f1e8dc;line-height:1.75;margin:0}.archive-new-button{display:flex;align-items:center;gap:.65rem;border-radius:999px;padding:.85rem 1.25rem;background:#fff;color:#855b28;font-weight:800;white-space:nowrap;box-shadow:0 10px 25px rgba(0,0,0,.14)}.archive-new-button span{font-size:1.3rem}.archive-board{margin-top:1.4rem;border:1px solid var(--line);border-radius:20px;background:var(--surface);padding:1.7rem}.archive-board-head{display:flex;align-items:end;justify-content:space-between;gap:1rem}.archive-board-head p{font-size:.68rem;letter-spacing:.15em;color:#ac7840;font-weight:800;margin:0}.archive-board-head h2{font-size:1.5rem;margin:.15rem 0 0}.archive-search{display:flex;width:min(410px,100%)}.archive-search input{width:100%;border:1px solid var(--line);border-right:0;border-radius:10px 0 0 10px;background:var(--bg);color:var(--ink);padding:.72rem .85rem}.archive-search button{border:0;border-radius:0 10px 10px 0;background:#9b6a34;color:#fff;padding:0 1.1rem;font-weight:700}.archive-filters{display:flex;gap:.45rem;padding:1rem 0;border-bottom:1px solid var(--line)}.archive-filters button{border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--muted);padding:.42rem .8rem;font-size:.76rem}.archive-filters button.active{border-color:#9b6a34;background:#9b6a34;color:#fff}.archive-empty{text-align:center;padding:4.5rem 1rem}.archive-empty>span{display:grid;place-items:center;width:64px;height:64px;margin:auto;border-radius:18px;background:#f7eee2;color:#a26d32;font-size:2rem}.archive-empty h3{font-size:1.15rem;margin:1rem 0 .35rem}.archive-empty p{color:var(--muted);font-size:.86rem;margin:0}.archive-empty a{display:inline-block;margin-top:1.2rem;color:#91602c;font-size:.84rem;font-weight:800}.archive-editor-heading{display:flex;align-items:end;justify-content:space-between;margin-bottom:1.2rem}.archive-editor-heading h1{font-size:2.2rem;margin:.2rem 0}.archive-editor-heading>div>p:last-child{color:var(--muted);margin:0}.archive-step{border-radius:999px;background:#f6eddf;color:#98672f;padding:.45rem .8rem;font-size:.72rem;font-weight:800}.archive-editor-form{border:1px solid var(--line);border-radius:20px;background:var(--surface);padding:1.5rem;box-shadow:0 10px 30px rgba(38,59,86,.05)}.archive-meta-grid{display:grid;grid-template-columns:2fr .7fr 1.4fr 1fr;gap:.8rem;margin-bottom:1rem}.archive-meta-grid>label>span,.archive-meta-grid legend{display:block;font-size:.76rem;font-weight:700;margin-bottom:.4rem}.archive-meta-grid small{font-weight:400;color:var(--muted)}.archive-meta-grid input,.archive-meta-grid select{width:100%;height:44px;border:1px solid var(--line);border-radius:9px;background:var(--bg);color:var(--ink);padding:0 .8rem}.archive-meta-grid fieldset{border:0;padding:0;margin:0}.archive-meta-grid fieldset label{font-size:.78rem;margin-right:.7rem}.archive-paste-guide{display:flex;align-items:center;justify-content:center;gap:.65rem;border-radius:10px;background:#faf5ed;color:#6f5334;padding:.75rem;margin-bottom:1rem;font-size:.75rem}.archive-paste-guide b{color:#8d5b25}.archive-paste-guide i{font-style:normal;color:#b89b78}.archive-editor-actions{display:flex;justify-content:flex-end;align-items:center;gap:.55rem;margin-top:1rem}.archive-editor-actions>a,.archive-editor-actions button{border-radius:9px;padding:.72rem 1rem;font-size:.8rem;font-weight:700}.archive-editor-actions>a{margin-right:auto;color:var(--muted)}.archive-preview-button{border:1px solid #9b6a34;background:#fff;color:#895b29}.archive-save-button{border:1px solid #9b6a34;background:#9b6a34;color:#fff}.archive-save-button:disabled{opacity:.45;cursor:not-allowed}.archive-stage-note{text-align:right;color:var(--muted);font-size:.7rem;margin:.6rem 0 0}.archive-preview-modal{width:min(900px,calc(100% - 2rem));max-height:calc(100vh - 2rem);border:0;border-radius:18px;padding:2.4rem;background:#fff;color:#202b3a;box-shadow:0 28px 80px rgba(7,25,48,.35)}.archive-preview-modal::backdrop{background:rgba(5,17,32,.68);backdrop-filter:blur(5px)}.archive-preview-close{position:absolute;right:1rem;top:.8rem;border:0;background:transparent;color:#687789;font-size:1.8rem}.archive-preview-modal>h1{font-size:2rem;margin:.35rem 0}.archive-preview-meta{display:flex;gap:1rem;border-bottom:1px solid #dde4ec;padding-bottom:1rem;color:#8c622f;font-size:.78rem}.archive-preview-modal article{font-size:1rem;line-height:1.8;padding:1rem 0}.archive-preview-modal article img{max-width:100%;height:auto}.archive-preview-modal article table{width:100%;border-collapse:collapse}.archive-preview-modal article td,.archive-preview-modal article th{border:1px solid #ccd5e0;padding:.5rem}.dark .archive-board,.dark .archive-editor-form{background:#172131}.dark .archive-paste-guide{background:#30281e;color:#e3d3bd}.dark .archive-empty>span{background:#30281e}
@media(max-width:900px){.archive-meta-grid{grid-template-columns:1fr 1fr}}
@media(max-width:760px){.archive-hero{padding:2rem;min-height:340px;align-items:flex-start;flex-direction:column;justify-content:center}.archive-new-button{width:100%;justify-content:center}.archive-board{padding:1.1rem}.archive-board-head{align-items:stretch;flex-direction:column}.archive-search{width:100%}.archive-filters{overflow-x:auto}.archive-filters button{white-space:nowrap}.archive-empty{padding:3rem .5rem}.archive-editor-heading{align-items:flex-start;flex-direction:column;gap:.8rem}.archive-editor-heading h1{font-size:1.7rem}.archive-editor-form{padding:1rem}.archive-meta-grid{grid-template-columns:1fr}.archive-paste-guide{align-items:flex-start;flex-direction:column}.archive-paste-guide i{display:none}.archive-editor-actions{flex-wrap:wrap}.archive-editor-actions>a{width:100%}.archive-preview-button,.archive-save-button{flex:1}.archive-stage-note{text-align:left}.archive-preview-modal{padding:1.4rem}.archive-preview-modal>h1{font-size:1.55rem}}

/* Archive data and admin */
.archive-list-head,.archive-list-row{display:grid;grid-template-columns:100px minmax(0,1fr) 80px 100px;gap:1rem;align-items:center}.archive-list-head{padding:.85rem 1rem;color:var(--muted);font-size:.7rem;border-bottom:1px solid var(--line)}.archive-list-row{padding:1rem;border-bottom:1px solid var(--line);font-size:.8rem;transition:background .2s}.archive-list-row:hover{background:var(--bg)}.archive-list-row>span:first-child{color:#95642e;font-weight:700}.archive-list-row strong{display:block;font-size:.92rem}.archive-list-row small{display:block;margin-top:.25rem;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.visibility-badge{justify-self:start;border-radius:999px;background:#e7f6ef;color:#20815d;padding:.25rem .55rem;font-size:.68rem;font-weight:700}.visibility-badge.private,.archive-document-badges .private{background:#eee9ff;color:#6948c9}.archive-list-row time{color:var(--muted)}.setup-page,.login-page{min-height:calc(100vh - 200px);display:grid;place-items:center}.setup-card,.login-card{width:min(520px,100%);border:1px solid var(--line);border-radius:20px;background:var(--surface);padding:2rem;box-shadow:var(--shadow)}.setup-card h1,.login-card h1{font-size:1.8rem;margin:.25rem 0 .5rem}.setup-card>p,.login-card>p{color:var(--muted);font-size:.86rem}.setup-card form,.login-card form{display:grid;gap:1rem;margin-top:1.4rem}.setup-card label,.login-card label{display:grid;gap:.4rem;font-size:.8rem;font-weight:700}.setup-card label small{color:var(--muted);font-weight:400}.setup-card input,.login-card input{height:46px;border:1px solid var(--line);border-radius:9px;background:var(--bg);color:var(--ink);padding:0 .85rem}.setup-card button,.login-card button{border:0;border-radius:9px;background:#8f612d;color:#fff;padding:.8rem;font-weight:800}.setup-error{border-radius:9px;background:#fff0f0;color:#b42318!important;padding:.75rem 1rem;font-weight:700}.login-card>a{display:inline-block;margin-top:1rem;color:var(--muted);font-size:.76rem}.archive-document{max-width:940px;margin:auto;border:1px solid var(--line);border-radius:20px;background:var(--surface);padding:clamp(1.4rem,4vw,3.5rem);box-shadow:0 10px 30px rgba(38,59,86,.05)}.archive-document header{border-bottom:1px solid var(--line);padding-bottom:1.3rem}.archive-document-badges{display:flex;gap:.45rem}.archive-document-badges span{border-radius:999px;background:#f6eddf;color:#91602c;padding:.28rem .62rem;font-size:.7rem;font-weight:700}.archive-document h1{font-size:clamp(1.8rem,4vw,2.7rem);line-height:1.3;margin:.8rem 0}.archive-document-info{display:flex;justify-content:space-between;color:var(--muted);font-size:.76rem}.archive-document-info a{color:#8d5b25}.archive-saved{border-radius:9px;background:#e4f7ef;color:#087852;padding:.7rem 1rem;font-size:.8rem;font-weight:700}.archive-document-content{font-size:1rem;line-height:1.85;padding-top:1.5rem;overflow-wrap:anywhere}.archive-document-content img{max-width:100%;height:auto}.archive-document-content table{width:100%;border-collapse:collapse;display:block;overflow-x:auto}.archive-document-content td,.archive-document-content th{border:1px solid var(--line);padding:.5rem}.archive-not-found{text-align:center;padding:5rem 1rem}.archive-not-found a{color:#8d5b25}.dark .setup-card,.dark .login-card,.dark .archive-document{background:#172131}
@media(max-width:760px){.archive-list-head{display:none}.archive-list-row{grid-template-columns:1fr auto;padding:1rem .3rem}.archive-list-row>span:first-child{grid-column:1}.archive-list-row>span:nth-child(2){grid-column:1/-1;grid-row:2}.archive-list-row .visibility-badge{grid-column:2;grid-row:1}.archive-list-row time{grid-column:1/-1;grid-row:3}.setup-card,.login-card{padding:1.4rem}.archive-document-info{align-items:flex-start;flex-direction:column;gap:.5rem}}

/* Archive readability */
.archive-document-info a,.archive-preview-meta a{font-size:1rem;font-weight:800}
.archive-admin-actions{display:flex;justify-content:flex-end;align-items:center;gap:.55rem;margin-top:1rem}.archive-admin-actions form{margin:0}.archive-admin-actions a,.archive-admin-actions button{display:inline-flex;align-items:center;justify-content:center;min-width:72px;border-radius:9px;padding:.55rem .9rem;font:inherit;font-size:.84rem;font-weight:800;cursor:pointer}.archive-admin-actions a{border:1px solid #9b6a34;color:#895b29}.archive-admin-actions button{border:1px solid #cf4c4c;background:#fff;color:#b52f2f}
.archive-meta-grid .archive-visibility{display:flex;flex-direction:column;align-items:flex-start;gap:.35rem}.archive-meta-grid .archive-visibility legend{width:100%;margin-bottom:.35rem}.archive-meta-grid .archive-visibility label{display:grid;grid-template-columns:18px auto;align-items:center;gap:.45rem;min-height:22px;margin:0;font-size:.8rem;line-height:1}.archive-meta-grid .archive-visibility input{width:16px;height:16px;margin:0}.archive-meta-grid .archive-visibility span{display:block;line-height:1.2}
@media(min-width:901px){.archive-meta-grid{grid-template-columns:minmax(250px,1.55fr) minmax(105px,.55fr) minmax(340px,2.25fr) 105px}.archive-meta-grid .archive-visibility{width:105px;justify-self:end}}

/* Links */
.links-page{max-width:1320px}.links-hero{min-height:285px;border-radius:24px;padding:3rem 3.4rem;background:linear-gradient(120deg,#0d5a46f2,#2f9d78d9),url('../images/hero-lake.png') center 54%/cover;color:#fff;display:flex;align-items:center;justify-content:space-between;gap:2rem}.links-hero h1{font-size:clamp(2rem,4vw,3.15rem);line-height:1.25;margin:.3rem 0 .8rem}.links-hero p:last-child{max-width:620px;color:#e6f7f0;line-height:1.75;margin:0}.links-new-button{display:flex;align-items:center;gap:.6rem;border-radius:999px;padding:.85rem 1.2rem;background:#fff;color:#167356;font-weight:800;white-space:nowrap;box-shadow:0 10px 25px rgba(0,0,0,.14)}.links-new-button span{font-size:1.3rem}.links-directory{margin-top:1.4rem;border:1px solid var(--line);border-radius:20px;background:var(--surface);padding:1.7rem}.links-directory-head{display:flex;align-items:end;justify-content:space-between;gap:1rem}.links-directory-head>div>p{margin:0;color:#29946f;font-size:.68rem;font-weight:800;letter-spacing:.15em}.links-directory-head h2{font-size:1.5rem;margin:.15rem 0 0}.links-search{display:flex;width:min(430px,100%)}.links-search input{width:100%;border:1px solid var(--line);border-right:0;border-radius:10px 0 0 10px;background:var(--bg);color:var(--ink);padding:.72rem .85rem}.links-search button{border:0;border-radius:0 10px 10px 0;background:#228361;color:#fff;padding:0 1.1rem;font-weight:700}.links-filters{display:flex;gap:.45rem;padding:1rem 0;border-bottom:1px solid var(--line);overflow-x:auto}.links-filters a{border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--muted);padding:.43rem .82rem;font-size:.78rem;white-space:nowrap}.links-filters a.active{border-color:#228361;background:#228361;color:#fff}.links-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem;padding-top:1.2rem}.saved-link-card{position:relative;display:flex;flex-direction:column;min-height:250px;border:1px solid var(--line);border-radius:16px;background:var(--bg);padding:1.2rem;transition:transform .2s,box-shadow .2s}.saved-link-card:hover{transform:translateY(-3px);box-shadow:var(--shadow)}.saved-link-card.favorite{border-color:#d8b66f}.saved-link-top{display:flex;align-items:center;justify-content:space-between;gap:.7rem}.saved-link-top>div{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:.3rem}.saved-link-icon{display:grid;place-items:center;width:43px;height:43px;border-radius:12px;background:#dff5ec;color:#157355;font-size:1.15rem;font-weight:900}.saved-link-category,.saved-link-star{border-radius:999px;padding:.24rem .5rem;font-size:.67rem;font-weight:800}.saved-link-category{background:#e6f4ef;color:#26765d}.saved-link-star{background:#fff2cc;color:#946717}.saved-link-card h3{font-size:1.18rem;margin:1rem 0 .35rem}.saved-link-card>p{flex:1;color:var(--muted);font-size:.86rem;line-height:1.65;margin:0}.saved-link-card>small{margin-top:.8rem;color:#6b7a8c;font-size:.72rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.saved-link-actions{display:flex;align-items:center;gap:.45rem;margin-top:1rem}.saved-link-actions a,.saved-link-actions button{border:0;background:transparent;color:var(--muted);font:inherit;font-size:.74rem;cursor:pointer}.saved-link-actions .saved-link-open{margin-right:auto;border-radius:999px;background:#187b5b;color:#fff;padding:.55rem .8rem;font-size:.8rem;font-weight:800}.saved-link-actions form{margin:0}.links-empty{text-align:center;padding:4rem 1rem}.links-empty>span{display:grid;place-items:center;width:62px;height:62px;margin:auto;border-radius:18px;background:#e1f4ed;color:#238060;font-size:1.8rem}.links-empty h3{margin:1rem 0 .35rem}.links-empty p{color:var(--muted);font-size:.88rem}.links-empty a{display:inline-block;margin-top:1rem;color:#187b5b;font-weight:800}.link-form-page{max-width:900px}.link-form-heading h1{font-size:2.25rem;margin:.2rem 0}.link-form-heading>p:last-child{color:var(--muted)}.link-editor-form{display:grid;gap:1.15rem;margin-top:1.3rem;border:1px solid var(--line);border-radius:20px;background:var(--surface);padding:1.7rem;box-shadow:0 10px 30px rgba(38,59,86,.05)}.link-editor-form>label,.link-form-grid label{display:grid;gap:.42rem}.link-editor-form label>span:first-child,.link-form-grid label>span:first-child{font-size:.82rem;font-weight:800}.link-editor-form label small{color:var(--muted);font-weight:400}.link-editor-form input,.link-editor-form select,.link-editor-form textarea{width:100%;border:1px solid var(--line);border-radius:10px;background:var(--bg);color:var(--ink);padding:.78rem .9rem;font:inherit}.link-editor-form input,.link-editor-form select{height:48px}.link-editor-form textarea{resize:vertical}.link-url-field input{font-size:1rem}.link-form-grid{display:grid;grid-template-columns:2fr 1fr;gap:1rem}.link-options{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;border-radius:12px;background:var(--bg);padding:1rem}.link-options fieldset{border:0;padding:0;margin:0}.link-options legend{font-size:.78rem;font-weight:800;margin-bottom:.45rem}.link-options fieldset label{display:inline-flex;align-items:center;gap:.35rem;margin-right:.8rem;font-size:.8rem}.link-options input[type=radio],.link-options input[type=checkbox]{width:17px;height:17px;margin:0}.favorite-option{display:flex!important;align-items:center;gap:.55rem}.favorite-option>span{display:grid}.favorite-option b{font-size:.82rem}.favorite-option small{font-size:.7rem}.link-form-actions{display:flex;align-items:center;justify-content:flex-end;gap:.6rem}.link-form-actions a{margin-right:auto;color:var(--muted)}.link-form-actions button{border:0;border-radius:10px;background:#187b5b;color:#fff;padding:.78rem 1.2rem;font-weight:800}.dark .links-directory,.dark .link-editor-form{background:#172131}.dark .saved-link-icon{background:#173e32}.dark .link-options{background:#111c2a}
@media(max-width:900px){.links-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.links-hero{padding:2rem;min-height:330px;align-items:flex-start;flex-direction:column;justify-content:center}.links-new-button{width:100%;justify-content:center}.links-directory{padding:1.1rem}.links-directory-head{align-items:stretch;flex-direction:column}.links-search{width:100%}.links-grid{grid-template-columns:1fr}.link-form-heading h1{font-size:1.8rem}.link-editor-form{padding:1rem}.link-form-grid{grid-template-columns:1fr}.link-options{flex-direction:column}.link-options fieldset label{display:flex;margin:.35rem 0}.favorite-option{margin-top:.4rem}}
/* Private Notes */
.notes-home,.diary-page,.memo-page,.diary-editor,.diary-read{max-width:1180px;margin:auto}.notes-heading{padding:48px 4px 28px}.notes-heading h1,.notes-list-head h1{font-size:clamp(2.2rem,5vw,4.8rem);line-height:1.05;margin:.3rem 0 1rem;color:#101d31}.notes-heading>p:last-child,.notes-list-head p{font-size:1.05rem;color:#607086}.notes-door-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px}.notes-door{position:relative;min-height:390px;padding:42px;border-radius:28px;color:#17253a;text-decoration:none;overflow:hidden;box-shadow:0 18px 50px rgba(25,46,78,.1);transition:.2s transform}.notes-door:hover{transform:translateY(-4px)}.diary-door{background:linear-gradient(145deg,#fff9ed,#f4e0bd)}.memo-door{background:linear-gradient(145deg,#edf5ff,#dfe9ff)}.notes-door-icon{display:grid;width:66px;height:66px;place-items:center;border-radius:20px;background:#fff;font-size:2rem;box-shadow:0 8px 24px #0001}.notes-door small{display:block;margin-top:40px;font-weight:800;letter-spacing:.16em;color:#68788e}.notes-door h2{font-size:2.3rem;margin:.4rem 0}.notes-door p{font-size:1.08rem;line-height:1.7;max-width:370px}.notes-door strong{position:absolute;bottom:42px;left:42px;font-size:1.05rem}.notes-door strong b{margin-left:8px}.notes-door em{position:absolute;right:36px;bottom:42px;color:#68788e;font-size:.9rem}.notes-list-head{display:flex;justify-content:space-between;align-items:end;padding:36px 0 26px}.notes-list-head h1{font-size:3.4rem}.notes-primary{display:inline-flex;padding:15px 22px;border-radius:14px;background:#246df0;color:#fff;text-decoration:none;font-weight:800}.private-chip{padding:10px 14px;border-radius:999px;background:#efeaff;color:#6948d9;font-weight:800}.notes-filter,.memo-toolbar{display:flex;gap:10px;margin-bottom:24px}.notes-filter input,.memo-toolbar input{min-height:48px;padding:0 15px;border:1px solid #ccd7e5;border-radius:12px;font:inherit}.notes-filter input[type=search]{flex:1}.notes-filter button,.memo-toolbar button{border:0;border-radius:12px;padding:0 22px;background:#172b46;color:#fff;font-weight:800}.notes-filter a{align-content:center;padding:0 12px;color:#63728a}.diary-timeline{display:grid;gap:14px}.diary-item{display:grid;grid-template-columns:150px 1fr auto;gap:24px;align-items:center;padding:18px;background:#fff;border:1px solid #dce5ef;border-radius:20px;text-decoration:none;color:#17253a}.diary-item img,.diary-date-art{width:150px;height:110px;border-radius:14px;object-fit:cover}.diary-date-art{display:grid;place-items:center;background:#fff2db;font-size:2.4rem;font-weight:900;color:#b37825}.diary-item time{font-size:.9rem;color:#68788e}.diary-item h2{margin:.3rem 0;font-size:1.35rem}.diary-item p{margin:0;color:#66758a;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.diary-item>b{font-size:1.4rem}.notes-empty{text-align:center;padding:70px 20px;border:1px dashed #c8d4e2;border-radius:22px}.notes-empty>span{font-size:3rem}.notes-empty a{color:#246df0;font-weight:800}.diary-form,.memo-compose,.diary-read article{background:#fff;border:1px solid #dbe4ef;border-radius:24px;padding:30px;box-shadow:0 18px 45px #263d5d10}.diary-form label{display:grid;gap:8px;margin-bottom:18px;font-weight:800}.diary-form input,.diary-form textarea,.memo-compose textarea{width:100%;border:1px solid #cbd7e5;border-radius:12px;padding:14px;font:inherit;line-height:1.7}.diary-form-row{display:grid;grid-template-columns:1fr 1fr;gap:16px}.photo-picker{padding:18px;background:#f5f8fc;border-radius:14px}.notes-actions{display:flex;justify-content:flex-end;gap:14px;align-items:center}.notes-actions a{color:#68788e}.notes-actions button,.memo-compose>button{border:0;border-radius:12px;padding:14px 25px;background:#246df0;color:#fff;font-weight:800;font-size:1rem}.diary-read article{max-width:900px;margin:32px auto}.diary-read header{text-align:center;padding:22px}.diary-read h1{font-size:2.4rem;margin:.6rem}.diary-gallery{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin:20px 0}.diary-gallery img{width:100%;max-height:520px;object-fit:contain;border-radius:14px;background:#edf1f6}.diary-content{font-size:1.08rem;line-height:2;padding:30px 4px;min-height:180px}.diary-read article>footer,.memo-item footer{display:flex;gap:10px;align-items:center;border-top:1px solid #e1e8f0;padding-top:18px}.diary-read footer form{margin-left:auto}.diary-read button,.memo-item button{border:0;background:none;color:#7b8796;cursor:pointer}.memo-compose{display:grid;grid-template-columns:1fr auto;gap:12px;align-items:end;margin-bottom:24px}.memo-compose textarea{grid-column:1/-1;resize:vertical}.memo-compose label{font-weight:700}.memo-toolbar{justify-content:space-between;align-items:center}.memo-toolbar form{display:flex;gap:8px}.memo-toolbar nav{display:flex;background:#edf2f8;border-radius:12px;padding:4px}.memo-toolbar nav a{padding:9px 14px;text-decoration:none;color:#65748a;border-radius:9px;font-weight:700}.memo-toolbar nav a.active{background:#fff;color:#17253a;box-shadow:0 2px 8px #0001}.memo-list{display:grid;grid-template-columns:repeat(2,1fr);gap:14px}.memo-item{padding:22px;border:1px solid #dbe4ef;border-radius:18px;background:#fff}.memo-item.pinned{border-color:#f0c66f;background:#fffaf0}.memo-item>p{min-height:70px;line-height:1.7}.memo-item footer time{margin-right:auto;color:#79879a;font-size:.85rem}.memo-item footer span{color:#b57a0b;font-weight:800}.memo-item footer form{display:inline}.notes-home~.site-footer{}
.notes-head-actions,.diary-manage,.memo-edit-actions{display:flex;align-items:center;gap:12px}.notes-home-button{display:inline-flex;padding:13px 18px;border:1px solid #cbd7e5;border-radius:14px;background:#fff;color:#42546c;text-decoration:none;font-weight:800}.diary-read article>footer .diary-back{margin-right:auto}.diary-read footer form{margin-left:0}.diary-manage{margin-left:auto;gap:18px;padding-left:28px;border-left:1px solid #dce4ed}.memo-edit-actions{justify-content:flex-end}.memo-edit-actions a{padding:13px 20px;color:#68788e;text-decoration:none}.memo-edit-actions button{border:0;border-radius:12px;padding:14px 25px;background:#246df0;color:#fff;font-weight:800;font-size:1rem}
@media(max-width:720px){.notes-door-grid,.memo-list{grid-template-columns:1fr}.notes-door{min-height:330px;padding:28px}.notes-door strong{left:28px;bottom:28px}.notes-door em{display:none}.notes-list-head{align-items:flex-start;gap:18px}.notes-head-actions{align-items:flex-end;flex-direction:column}.notes-list-head h1{font-size:2.5rem}.notes-filter{flex-wrap:wrap}.notes-filter input[type=search]{flex-basis:100%}.diary-item{grid-template-columns:92px 1fr;padding:12px;gap:14px}.diary-item img,.diary-date-art{width:92px;height:90px}.diary-item>b{display:none}.diary-item p{max-width:210px}.diary-form-row{grid-template-columns:1fr}.diary-form,.memo-compose,.diary-read article{padding:20px}.diary-gallery{grid-template-columns:1fr}.memo-compose{grid-template-columns:1fr}.memo-toolbar{align-items:stretch;flex-direction:column}.memo-toolbar form input{min-width:0;flex:1}}

/* About */
.about-page{max-width:1240px;margin:auto}.about-intro{display:grid;grid-template-columns:minmax(320px,.78fr) 1.22fr;gap:clamp(45px,7vw,100px);align-items:center;padding:52px 12px 86px}.about-portrait-wrap{position:relative;max-width:460px;margin:auto}.about-portrait-wrap>img{position:relative;z-index:2;display:block;width:100%;aspect-ratio:4/5;object-fit:cover;object-position:center 22%;border-radius:220px 220px 34px 34px;background:#fff;box-shadow:0 28px 65px rgba(19,36,59,.16)}.about-orbit{position:absolute;z-index:1;inset:-24px 34px 68px -24px;border:1px solid #adc8ef;border-radius:50%}.about-portrait-wrap>p{position:absolute;z-index:3;right:-20px;bottom:24px;margin:0;padding:16px 22px;border-radius:16px;background:#152840;color:#fff;box-shadow:0 14px 32px rgba(14,32,55,.25)}.about-portrait-wrap>p b,.about-portrait-wrap>p span{display:block}.about-portrait-wrap>p b{font-size:1.15rem}.about-portrait-wrap>p span{margin-top:2px;color:#bdcbe0;font-size:.74rem}.about-intro-copy h1{margin:.5rem 0 1.5rem;color:#12233a;font-size:clamp(2.35rem,4.5vw,4.6rem);line-height:1.2;letter-spacing:-.045em}.about-lead{max-width:690px;color:#586a80;font-size:1.12rem;line-height:1.85}.about-signature{display:flex;align-items:center;gap:20px;margin-top:34px}.about-signature>span{width:65px;height:1px;background:#7a8ca2}.about-signature p{margin:0;color:#344a65;font-size:.96rem;line-height:1.65;font-weight:700}.about-story{display:grid;grid-template-columns:1fr 1fr;gap:70px;padding:72px 58px;border-radius:28px;background:#142941;color:#fff}.about-story h2{margin:.5rem 0 0;font-size:clamp(1.85rem,3vw,2.7rem);line-height:1.5}.about-story-copy{display:grid;gap:18px}.about-story-copy p{margin:0;color:#d2dcea;font-size:1.02rem;line-height:1.9}.about-spaces{padding:92px 0}.about-section-title{text-align:center;margin-bottom:34px}.about-section-title h2{margin:.35rem 0;font-size:2.4rem;color:#14243a}.about-space-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}.about-space-grid>a{display:flex;flex-direction:column;min-height:285px;padding:26px;border:1px solid #d9e3ee;border-radius:20px;background:#fff;color:#17263b;text-decoration:none;transition:.22s transform,.22s box-shadow}.about-space-grid>a:hover{transform:translateY(-5px);box-shadow:0 20px 42px rgba(30,53,83,.12)}.about-space-grid span{color:#8ca0b7;font-weight:800}.about-space-grid h3{margin:30px 0 8px;font-size:1.65rem}.about-space-grid p{margin:0;color:#64758a;line-height:1.65}.about-space-grid b{margin-top:auto;color:#286bd7}.about-values{display:grid;grid-template-columns:.9fr 1.1fr;gap:0;overflow:hidden;border-radius:28px;background:linear-gradient(145deg,#f1e7d7,#faf7f1)}.about-values-quote{padding:58px;background:#e6ceb0}.about-values-quote>span{font-size:4rem;color:#9c6f3e;line-height:1}.about-values-quote h2{margin:0;font-size:2.25rem;line-height:1.4;color:#382c21}.about-values-quote p{margin-top:28px;color:#795b3e;font-style:italic}.about-values-list{padding:38px 52px}.about-values-list article{display:flex;gap:24px;padding:20px 0;border-bottom:1px solid #d8cbb9}.about-values-list article:last-child{border-bottom:0}.about-values-list article>b{color:#a57b49;font-size:.82rem}.about-values-list h3{margin:0 0 5px;font-size:1.2rem}.about-values-list p{margin:0;color:#6e6256;line-height:1.65}.about-contact{display:flex;justify-content:space-between;align-items:center;gap:30px;margin:82px 0 20px;padding:34px 42px;border:1px solid #d8e2ee;border-radius:22px;background:#fff}.about-contact h2{margin:.25rem 0;font-size:1.75rem}.about-contact>div>p:last-child{margin:.5rem 0 0;color:#65758a}.about-contact>a{display:flex;align-items:center;gap:22px;padding:16px 20px;border-radius:999px;background:#246de9;color:#fff;text-decoration:none;font-weight:800}.about-contact>a span{font-size:1.2rem}.dark .about-intro-copy h1,.dark .about-section-title h2{color:#eef4fb}.dark .about-space-grid>a,.dark .about-contact{background:#172131;border-color:#35455a;color:#eef4fb}.dark .about-space-grid p,.dark .about-contact>div>p:last-child{color:#b9c6d6}.dark .about-values{background:#332d26}.dark .about-values-list p{color:#cbbda9}
@media(max-width:900px){.about-intro{grid-template-columns:1fr}.about-portrait-wrap{width:min(430px,85%)}.about-story{grid-template-columns:1fr;gap:30px}.about-space-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:650px){.about-intro{padding-top:34px}.about-portrait-wrap>p{right:-10px}.about-intro-copy h1{font-size:2.25rem}.about-story{padding:38px 26px}.about-spaces{padding:65px 0}.about-space-grid{grid-template-columns:1fr}.about-space-grid>a{min-height:220px}.about-values{grid-template-columns:1fr}.about-values-quote,.about-values-list{padding:34px 26px}.about-contact{align-items:flex-start;flex-direction:column;padding:28px}.about-contact>a{width:100%;justify-content:space-between}}
.about-intro-copy h1{font-size:clamp(2.35rem,3.3vw,3.35rem);line-height:1.25;word-break:keep-all}.about-story h2{word-break:keep-all}

/* Gallery */
.gallery-page{max-width:1320px;margin:auto}.gallery-heading{display:flex;justify-content:space-between;align-items:end;gap:30px;padding:44px 4px 34px}.gallery-heading h1{margin:.35rem 0 .8rem;color:#14243a;font-size:clamp(2.4rem,4vw,4.2rem);line-height:1.18}.gallery-heading>div>p:last-child{color:#62738a;font-size:1.02rem}.gallery-upload-button{display:inline-flex;align-items:center;justify-content:center;padding:15px 22px;border-radius:999px;background:#6451d8;color:#fff;text-decoration:none;font-weight:800;white-space:nowrap}.gallery-browser{padding:20px 0 50px}.gallery-filter{display:flex;gap:9px;margin-bottom:22px}.gallery-filter select{min-height:46px;padding:0 36px 0 13px;border:1px solid #d3deea;border-radius:11px;background:#fff;color:#28394f;font:inherit}.gallery-filter button{border:0;border-radius:11px;padding:0 20px;background:#172b46;color:#fff;font-weight:800}.gallery-filter>a{align-content:center;padding:0 8px;color:#687991}.gallery-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.gallery-tile{position:relative;overflow:hidden;min-height:330px;border-radius:18px;background:#dce4ed;color:#fff;text-decoration:none}.gallery-tile img{display:block;width:100%;height:100%;min-height:330px;object-fit:cover;transition:transform .4s ease}.gallery-tile:hover img{transform:scale(1.035)}.gallery-tile-shade{position:absolute;inset:35% 0 0;background:linear-gradient(transparent,rgba(8,17,30,.83))}.gallery-tile>div{position:absolute;z-index:2;left:22px;right:22px;bottom:20px}.gallery-tile small{font-size:.75rem;color:#dce4ef}.gallery-tile h2{margin:.3rem 0 0;font-size:1.35rem}.gallery-tile em{display:inline-block;margin-top:8px;font-style:normal}.gallery-empty{text-align:center;padding:90px 20px;border:1px dashed #c8d5e3;border-radius:22px}.gallery-empty>span{font-size:3.2rem;color:#7763df}.gallery-empty p{color:#6c7b8f}.gallery-pages{display:flex;justify-content:center;gap:6px;margin-top:30px}.gallery-pages a{display:grid;width:40px;height:40px;place-items:center;border:1px solid #d3ddea;border-radius:10px;color:#596a80;text-decoration:none}.gallery-pages a.active{background:#6451d8;color:#fff;border-color:#6451d8}.gallery-form-page{max-width:980px;margin:auto}.gallery-form-heading{display:flex;justify-content:space-between;align-items:center;padding:35px 0 22px}.gallery-form-heading h1{margin:.25rem 0;font-size:2.45rem}.gallery-form-heading p:last-child{color:#65758a}.gallery-form-heading>img{width:105px;height:105px;border-radius:18px;object-fit:cover}.gallery-form{display:grid;gap:20px;padding:28px;border:1px solid #d8e2ed;border-radius:22px;background:#fff;box-shadow:0 18px 45px rgba(26,47,74,.08)}.gallery-form>label,.gallery-form-grid>label{display:grid;gap:8px;font-weight:800}.gallery-form input,.gallery-form select,.gallery-form textarea{width:100%;border:1px solid #cbd7e4;border-radius:11px;padding:13px;background:#fff;font:inherit}.gallery-drop{position:relative;place-items:center;padding:38px!important;border:2px dashed #b7c6d9!important;border-radius:16px;background:#f6f9fd;color:#40536c;text-align:center}.gallery-drop>span{font-size:.78rem;color:#6451d8}.gallery-drop>strong{font-size:1.08rem}.gallery-drop>small{color:#78879a;font-weight:400}.gallery-drop input{max-width:460px;border:0;background:transparent}.gallery-form-grid{display:grid;grid-template-columns:1.5fr 1fr 1fr 1fr;gap:13px}.gallery-form-grid fieldset{display:flex;flex-wrap:wrap;gap:10px;border:1px solid #cbd7e4;border-radius:11px;padding:10px}.gallery-form-grid legend{font-size:.76rem;font-weight:800}.gallery-form-grid fieldset label{display:flex;align-items:center;gap:5px;font-size:.82rem}.gallery-form-grid fieldset input{width:16px}.gallery-form-actions{display:flex;justify-content:flex-end;align-items:center;gap:14px}.gallery-form-actions a{margin-right:auto;color:#65758a}.gallery-form-actions button{border:0;border-radius:11px;padding:14px 24px;background:#6451d8;color:#fff;font-weight:800}.gallery-view{max-width:1280px;margin:auto}.gallery-view>article{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(310px,.75fr);min-height:650px;margin:25px 0 50px;overflow:hidden;border-radius:24px;background:#111b28;box-shadow:0 22px 58px rgba(11,28,49,.2)}.gallery-view-image{position:relative;display:grid;place-items:center;background:#080d14}.gallery-view-image>img{display:block;max-width:100%;max-height:78vh;object-fit:contain}.gallery-arrow{position:absolute;top:50%;display:grid;width:48px;height:48px;place-items:center;border-radius:50%;background:rgba(255,255,255,.85);color:#15243a;text-decoration:none;font-size:2rem;transform:translateY(-50%)}.gallery-arrow.prev{left:18px}.gallery-arrow.next{right:18px}.gallery-view-info{display:flex;flex-direction:column;padding:42px 34px;background:#fff}.gallery-view-info>div>span{display:inline-block;margin-right:6px;color:#725fd5;font-weight:800}.gallery-view-info time{display:block;margin-top:22px;color:#7a899a}.gallery-view-info h1{margin:.5rem 0 1rem;font-size:2rem;line-height:1.35}.gallery-view-info p{color:#5d6e82;line-height:1.85}.gallery-view-info>footer{display:flex;align-items:center;margin-top:auto;padding-top:25px;border-top:1px solid #e0e7ef}.gallery-view-info>footer>a{color:#5f7085}.gallery-view-info>footer>div{display:flex;align-items:center;gap:14px;margin-left:auto}.gallery-view-info footer form{margin:0}.gallery-view-info footer button{border:0;background:none;color:#b53a3a;cursor:pointer}.dark .gallery-heading h1{color:#eef4fb}.dark .gallery-filter select,.dark .gallery-form,.dark .gallery-form input,.dark .gallery-form select,.dark .gallery-form textarea,.dark .gallery-view-info{background:#172131;color:#eef4fb;border-color:#3a4a5f}.dark .gallery-drop{background:#111c2a}.dark .gallery-view-info p{color:#c2cedc}
.gallery-tile>video{display:block;width:100%;height:100%;min-height:330px;object-fit:cover;background:#101927}.gallery-play{position:absolute;z-index:3;left:50%;top:45%;display:grid;width:58px;height:58px;place-items:center;padding-left:4px;border:2px solid rgba(255,255,255,.9);border-radius:50%;background:rgba(12,24,41,.65);color:#fff;font-size:1.25rem;transform:translate(-50%,-50%);box-shadow:0 8px 24px rgba(0,0,0,.28)}.gallery-view-image>video{display:block;width:100%;max-height:78vh;background:#000}.gallery-form-heading>video{width:105px;height:105px;border-radius:18px;object-fit:cover;background:#101927}
@media(max-width:950px){.gallery-grid{grid-template-columns:repeat(2,1fr)}.gallery-form-grid{grid-template-columns:1fr 1fr}.gallery-view>article{grid-template-columns:1fr}.gallery-view-info{min-height:330px}}
@media(max-width:650px){.gallery-heading{align-items:flex-start;flex-direction:column}.gallery-upload-button{width:100%}.gallery-filter{display:grid;grid-template-columns:1fr 1fr}.gallery-filter select:first-child{grid-column:1/-1}.gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.gallery-tile,.gallery-tile img,.gallery-tile>video{min-height:220px}.gallery-tile>div{left:14px;right:14px;bottom:14px}.gallery-tile h2{font-size:1rem}.gallery-play{width:48px;height:48px;font-size:1rem}.gallery-form-heading{align-items:flex-start;flex-direction:column}.gallery-form{padding:18px}.gallery-form-grid{grid-template-columns:1fr}.gallery-view>article{margin-top:15px}.gallery-view-image{min-height:360px}.gallery-view-info{padding:27px 22px}}

/* Home card spacing */
.links-card,.archive-card,.projects-card{min-height:290px;padding-bottom:4.5rem}.links-card ul,.archive-card ul,.projects-card ul{margin-bottom:1.4rem}.tool-list{grid-auto-rows:73px}

/* Admin session */
.admin-session{display:flex;align-items:center;gap:8px;padding:5px 6px 5px 10px;border:1px solid #d8e1ec;border-radius:999px;background:#f7f9fc;white-space:nowrap}.admin-session>span{display:flex;align-items:center;gap:6px;color:#34465c;font-size:.76rem;font-weight:800}.admin-session>span i{width:7px;height:7px;border-radius:50%;background:#24a873;box-shadow:0 0 0 3px rgba(36,168,115,.12)}.admin-session form{margin:0}.admin-session input{display:none}.admin-session button{border:0;border-radius:999px;padding:6px 10px;background:#e9eef5;color:#52647a;font-size:.7rem;font-weight:800}.admin-session button:hover{background:#dfe6ef;color:#25384f}.dark .admin-session{background:#172131;border-color:#35465b}.dark .admin-session>span{color:#dbe5f1}.dark .admin-session button{background:#26364a;color:#d5dfeb}
@media(max-width:1180px){.nav-actions{gap:.45rem}.admin-session>span{font-size:.7rem}.admin-session button{padding:5px 8px}.theme-button{padding:.5rem}}
@media(max-width:760px){.admin-session{padding-left:6px}.admin-session>span{font-size:0;gap:0}.admin-session>span i{width:8px;height:8px}.admin-session button{font-size:.68rem;padding:5px 7px}}
