
:root {
  
  --mint: #5BB4C0;
  --mint-dark: #3D93A0;
  --mint-light: #DBEEF1;
  --mint-lighter: #EAF6F8;
  --ink: #2c3a3a;
  --muted: #566a6a;
  --line: #D6EBEE;
  --bg: #FBE58F;
  --white: #ffffff;
  --warn: #e08a3c;
  --radius: 12px;
  
  --border: 2px solid var(--ink);
  --shadow: 4px 4px 0 var(--ink);
  --shadow-btn: 3px 3px 0 var(--ink);
  --shadow-sm: 2px 2px 0 var(--ink);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN",
    "Yu Gothic", "Noto Sans JP", Meiryo, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 15px;
  -webkit-text-size-adjust: 100%;
}
.wrap { max-width: 1100px; margin: 0 auto; padding: 14px 14px 16px; }

h1 {
  font-size: clamp(22px, 6vw, 28px); font-weight: 700;
  letter-spacing: .02em; margin-bottom: 4px;
}
h1 i { color: var(--mint-dark); }
.lead { font-size: 13px; color: var(--muted); margin-bottom: 14px; }

mark {
  background: linear-gradient(transparent 55%, rgba(255, 226, 92, .85) 55%);
  font-weight: 600; color: inherit; padding: 0 1px;
}
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  white-space: nowrap; border: 0;
}
.hide { display: none !important; }


.card {
  background: var(--white); border: var(--border); border-radius: var(--radius);
  box-shadow: none; padding: 14px; margin-bottom: 14px;
}
.card-h { font-size: 14px; font-weight: 800; color: var(--ink); margin: 0 0 12px; }
.card-h i { color: var(--mint-dark); }


.drop {
  border: 3px dashed #9aa5a5; border-radius: var(--radius);
  background: var(--mint-lighter); text-align: center;
  padding: 32px 16px; cursor: pointer; margin-bottom: 14px;
  transition: background .15s, border-color .15s;
}
.drop.over { border-color: var(--mint-dark); background: var(--mint-light); }

.drop .icon { font-size: 38px; display: block; margin: 0 auto 10px; color: var(--mint-dark); }
.drop .big { font-size: 16px; font-weight: 700; }
.drop .small { font-size: 12px; color: var(--muted); margin-top: 6px; }


.limit-note {
  margin: 0 0 14px; background: #FCF0DF; font-size: 12.5px; font-weight: 600;
}
.limit-note i { color: var(--warn); }
.limit-note b { color: var(--ink); }


.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.row.between { justify-content: space-between; }
.settings { display: flex; flex-wrap: wrap; gap: 20px 26px; }
.field { min-width: 200px; }
.field .title { display: block; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 7px; }
.hint { font-size: 12px; color: var(--muted); margin-top: 6px; }


.seg { display: inline-flex; border: var(--border); border-radius: 8px; overflow: hidden; box-shadow: var(--shadow-sm); }
.seg button {
  border: none; background: #fff; padding: 8px 14px; font-size: 13px;
  cursor: pointer; color: var(--muted); font-weight: 700; font-family: inherit;
  white-space: nowrap;
}
.seg button.active { background: var(--mint); color: #fff; }
@media (max-width: 599px) {
  .seg button { padding: 9px 9px; font-size: 12px; }
}


.check { display: flex; align-items: center; gap: 8px; font-size: 13px; margin-top: 8px; cursor: pointer; font-weight: 600; }
.check input { width: 18px; height: 18px; accent-color: var(--mint); flex-shrink: 0; }
input[type=range] { width: 170px; accent-color: var(--mint); vertical-align: middle; }
.qval { font-size: 14px; font-weight: 700; margin-left: 8px; }

#widthBox { margin-top: 10px; }
.wrow { display: flex; align-items: center; gap: 8px; }
#targetWidth {
  font-family: inherit; font-size: 15px; font-weight: 700; padding: 8px;
  border: var(--border); border-radius: 8px; background: #fff; color: var(--ink);
  width: 112px; text-align: right;
}
.unit { font-size: 13px; color: var(--muted); }
.presets { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }


.btn {
  border: var(--border); border-radius: 8px; padding: 10px 15px;
  font-size: 14px; font-weight: 700; cursor: pointer;
  background: var(--mint); color: #fff; box-shadow: var(--shadow-btn);
  transition: transform .08s, box-shadow .08s; font-family: inherit;
}
.btn.ghost { background: #fff; color: var(--mint-dark); }
.btn.small { padding: 6px 11px; font-size: 12px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.dl-big { font-size: 17px; padding: 13px 24px; box-shadow: var(--shadow); }

.chip {
  border: var(--border); border-radius: 8px; background: #fff; color: var(--muted);
  font-weight: 700; font-size: 12px; padding: 6px 11px; cursor: pointer;
  font-family: inherit; box-shadow: var(--shadow-sm);
  transition: transform .08s, box-shadow .08s;
}
.chip.active { background: var(--mint); color: #fff; }

@media (hover: hover) {
  .btn:hover:not(:disabled) { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); }
  .btn.dl-big:hover:not(:disabled) { background: #4AA6B3; transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--ink); }
  .chip:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--ink); }
}
.btn:active:not(:disabled) { transform: translate(3px, 3px); box-shadow: none; }
.btn.dl-big:active:not(:disabled) { background: var(--mint-dark); transform: translate(4px, 4px); box-shadow: none; }
.chip:active { background: var(--mint-light); transform: translate(2px, 2px); box-shadow: none; }


.note {
  font-size: 12px; color: var(--muted); background: var(--mint-lighter);
  border: var(--border); border-radius: 8px; padding: 10px 12px; margin-top: 10px;
}
.note b { color: var(--ink); }
.note i { color: var(--mint-dark); }


.status { font-size: 13px; font-weight: 700; color: var(--muted); }
.status i { color: var(--mint-dark); }
.filelist { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.fitem {
  display: flex; align-items: center; gap: 12px; background: var(--white);
  border: var(--border); border-radius: var(--radius); box-shadow: none; padding: 12px;
}
.thumb {
  width: 64px; height: 64px; border: var(--border); border-radius: 8px;
  object-fit: cover; background: var(--mint-lighter); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 22px;
}
.thumb i { color: var(--muted); }
img.thumb { display: block; }
.finfo { flex: 1; min-width: 0; }
.fname { font-size: 13px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge {
  display: inline-block; font-size: 10px; font-weight: 700; padding: 2px 8px;
  border-radius: 20px; background: var(--mint); color: #fff; margin-left: 6px; vertical-align: 1px;
}
.fmeta { font-size: 12px; color: var(--muted); margin-top: 3px; }
.fresult { font-size: 12px; margin-top: 3px; }
.fresult .ok { color: var(--mint-dark); font-weight: 700; }
.fresult .err { color: #e05555; font-weight: 700; }
.fresult .rnote { color: var(--muted); }
.fresult .rnote i { color: var(--mint-dark); }
.fresult b { color: var(--ink); }
.fa-spinner { color: var(--mint-dark); margin-right: 5px; }
.rm {
  border: none; background: none; color: var(--muted); font-size: 16px;
  cursor: pointer; flex-shrink: 0; padding: 6px; font-family: inherit;
}
.rm:hover { color: #e05555; }


.faq-head { font-size: 24px; margin: 20px 0 4px; color: var(--ink); font-weight: 700; }
.faq-head i { color: var(--mint-dark); }
.faq-cat { font-size: 16px; font-weight: 700; color: #1e2929; margin: 22px 0 10px; }
.faq-item { border: var(--border); border-radius: 8px; background: #fff; margin-bottom: 8px; overflow: hidden; }
.faq-item summary {
  list-style: none; display: flex; align-items: center; gap: 10px;
  padding: 13px 14px; min-height: 48px;
  font-size: 14px; font-weight: 600; cursor: pointer; color: var(--ink);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .q-ic { color: var(--mint-dark); flex-shrink: 0; }
.faq-item summary .chev { margin-left: auto; color: var(--muted); transition: transform .2s; flex-shrink: 0; }
.faq-item[open] summary .chev { transform: rotate(180deg); }
.faq-item[open] summary { border-bottom: 1px dashed var(--line); }
.faq-a { padding: 10px 14px 13px; font-size: 13px; color: var(--ink); line-height: 1.8; }
.faq-a a { color: var(--mint-dark); font-weight: 600; text-decoration: underline; }
.faq-more { font-size: 13px; color: var(--muted); margin: 12px 0 0; }
.faq-more a { color: var(--mint-dark); font-weight: 600; text-decoration: underline; }


.foot {
  text-align: center; color: #4d5c5c; font-size: 11px; padding: 20px 0;
  margin-top: 20px; border-top: 1px dashed var(--line);
}
.foot a { color: var(--mint-dark); }
.foot .foot-sep { color: var(--line); margin: 0 6px; font-weight: 400; }
.disclaimer-link {
  display: inline-block; font-size: 12px; color: var(--mint-dark);
  text-decoration: underline; cursor: pointer; background: none; border: none;
  font-family: inherit; padding: 0; vertical-align: baseline;
}


#disclaimerModal, #privacyModal {
  position: fixed; inset: 0; background: rgba(20,40,36,.45);
  display: none; align-items: center; justify-content: center; z-index: 80; padding: 14px;
}
#disclaimerModal.show, #privacyModal.show { display: flex; }
.dm-inner {
  background: #fff; width: 100%; max-width: 520px; max-height: 85vh;
  display: flex; flex-direction: column;
  border: var(--border); box-shadow: none;
  border-radius: 12px; padding: 16px; line-height: 1.7;
}
.dm-inner h3 { margin: 0 0 10px; font-size: 16px; color: var(--mint-dark); }
.dm-body {
  overflow-y: auto; flex: 1; min-height: 0; font-size: 12.5px; color: var(--ink);
  border: var(--border); border-radius: 8px; background: var(--mint-lighter); padding: 10px 12px;
}
.dm-body ul { margin: 0; padding-left: 18px; }
.dm-body li { margin-bottom: 6px; }
.dm-body li:last-child { margin-bottom: 0; }
.dm-body a { color: var(--mint-dark); font-weight: 600; text-decoration: underline; }
.dm-agree {
  display: flex; align-items: center; gap: 8px; margin: 12px 0 4px;
  font-size: 13px; font-weight: 600; cursor: pointer;
}
.dm-agree input { width: 18px; height: 18px; accent-color: var(--mint); flex-shrink: 0; }


.tabs { display: flex; gap: 0; margin-bottom: -2px; position: relative; z-index: 1; }
.tab-btn {
  flex: 1; padding: 11px 6px 12px; border: var(--border); border-bottom: 2px solid var(--ink);
  background: var(--white); border-radius: 0; font-size: 14px; font-weight: 700;
  color: var(--muted); cursor: pointer; box-shadow: none; font-family: inherit;
  display: flex; align-items: center; justify-content: center; gap: 7px; min-height: 48px;
}
.tab-btn:first-child { border-radius: 12px 0 0 0; }
.tab-btn:last-child { border-radius: 0 12px 0 0; }
.tab-btn:not(:first-child) { border-left: none; }
.tab-btn.active { background: var(--mint); color: #fff; border-bottom: none; }
.tab-btn i { color: var(--mint-dark); }
.tab-btn.active i { color: #fff; }
.tab-card { border-top-left-radius: 0; border-top-right-radius: 0; }
@media (max-width: 700px) {
  .tab-btn { font-size: 11px; padding: 9px 3px 10px; flex-direction: column; gap: 3px; }
}

.pane-desc { font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.pane-desc b { color: var(--ink); }
.sizerow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sizerow input[type=number] {
  font-family: inherit; font-size: 15px; font-weight: 700; padding: 8px;
  border: var(--border); border-radius: 8px; background: #fff; color: var(--ink);
  width: 100px; text-align: right;
}
.swap {
  border: var(--border); border-radius: 8px; background: #fff; color: var(--mint-dark);
  box-shadow: var(--shadow-sm); cursor: pointer; padding: 8px 10px; font-family: inherit;
  transition: transform .08s, box-shadow .08s;
}
@media (hover: hover) { .swap:hover { transform: translate(-1px,-1px); box-shadow: 3px 3px 0 var(--ink); } }
.swap:active { transform: translate(2px,2px); box-shadow: none; }
select {
  font-family: inherit; font-size: 13px; padding: 8px 28px 8px 8px; border: var(--border);
  border-radius: 8px; background: #fff; color: var(--ink);
  text-overflow: ellipsis; white-space: nowrap; overflow: hidden;
}
.divider { border: none; border-top: 1px dashed var(--line); margin: 14px 0 0; }


.app-header { background: var(--bg); border-bottom: var(--border); }
.app-header-inner {
  max-width: 1100px; margin: 0 auto; padding: 10px 14px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-mark { flex: 0 0 auto; display: flex; align-items: center; }
.brand-mark img { display: block; width: 44px; height: 44px; object-fit: contain; }
.brand-text { min-width: 0; }
.brand-title {
  margin: 0; font-size: 19px; font-weight: 800; letter-spacing: .01em;
  color: var(--ink); white-space: nowrap;
}
.brand-sub { margin: 0; font-size: 11.5px; color: var(--muted); letter-spacing: .03em; }
.brand-note { display: flex; align-items: center; gap: 14px; flex: 0 0 auto; }

.header-mascot { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1 1 auto; }
.hm-icon { width: 52px; height: 52px; flex-shrink: 0; display: block; }
.hm-bubble {
  position: relative; min-width: 0; flex: 1 1 auto;
  background: #fff; border: none; border-radius: 10px; padding: 6px 10px;
  box-shadow: 0 1px 4px rgba(44, 58, 58, .18);
}
.hm-bubble::after {
  content: ""; position: absolute; top: 50%; left: -6px; transform: translateY(-50%);
  border-style: solid; border-width: 5px 7px 5px 0;
  border-color: transparent #fff transparent transparent;
}
.hm-bubble p { margin: 0; font-size: 11px; font-weight: 700; color: var(--ink); line-height: 1.5; }
.hm-link {
  display: inline-block; margin-top: 2px; font-size: 10.5px; font-weight: 700;
  color: var(--mint-dark); text-decoration: underline; text-underline-offset: 2px;
  background: none; border: none; cursor: pointer; font-family: inherit; padding: 0;
}
.hm-link:hover { color: var(--ink); }
@media (max-width: 560px) {
  .app-header-inner { flex-wrap: wrap; row-gap: 8px; }
  .brand-note { width: 100%; justify-content: space-between; gap: 10px; }
  .hm-icon { width: 40px; height: 40px; }
  .hm-bubble { padding: 5px 8px; }
  .hm-bubble p { font-size: 10px; }
  .hm-link { font-size: 9.5px; }
}
