/* donate_nav.css v9 — 捐款頁獨立 navbar（不依賴 common.css）
   從 common.css 提取必要樣式，捐款頁專屬值直接內建，不再需要 override
   v8（2026-08-04）：tablet/mobile .top__minBtn 移除實心珊瑚色色塊，icon 改用 :before 置中顯示
   v9（2026-08-16）：.logo__text 補上 transition，修正往上捲動時文字瞬間跳回全尺寸、短暫穿出 header 疊在內容上的問題 */

/* ── Reset ──────────────────────────────────────────────── */
* {
  padding: 0;
  margin: 0;
  list-style-type: none;
  text-decoration: none;
}

.cf::before, .cf::after { content: ''; display: table; }
.cf::after { clear: both; }

body { line-height: 1; }

/* ── Page wrapper ───────────────────────────────────────── */
.wrapper {
  width: 100%;
  max-width: 2560px;
  margin: 0 auto;
  display: flow-root; /* BFC without breaking position:fixed on iOS Safari */
}

/* ── Desktop navbar (> 1300px) ──────────────────────────── */
@media (min-width: 1301px) {

.topper {
  width: 100%;
  height: 120px;
  background: #fff;
  position: fixed;
  z-index: 970;
  border-bottom: 2px solid #f08888;
  transition: height 0.25s ease;
  overflow: visible;
  user-select: none;
}

.topper .top__content {
  width: 100%;
  max-width: 1800px;
  min-width: 1300px;
  height: 120px;
  margin: 0 auto;
  transition: height 0.25s ease;
}

.topper .top__content .top__logo {
  margin-top: 18px;
  margin-left: 25px;
  width: auto;
  height: 85px;
  float: left;
  display: inline-block;
  transition: height 0.25s ease, padding 0.25s ease;
}

.topper .top__content .top__logo .logo__icon {
  width: 84px;
  height: 84px;
  display: block;
  float: left;
  background-size: cover;
  background-image: url('/static/images/desktop/icon/logo/logo_1x.png');
  transition: width 0.25s ease, height 0.25s ease;
}

@media (-webkit-min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) {
  .topper .top__content .top__logo .logo__icon {
    background-image: url('/static/images/desktop/icon/logo/logo_2x.png');
  }
}

.topper .top__content .top__logo .logo__text {
  width: 240px;
  height: 80px;
  display: block;
  float: left;
  font-size: 12.5px;
  padding: 44px 0 0 6px;
  color: #595959;
  position: relative;
  transition: height 0.25s ease, padding 0.25s ease;
}

.topper .top__content .top__logo .logo__text::after {
  content: '';
  display: block;
  width: 98px;
  height: 44px;
  position: absolute;
  top: 0;
  left: 0;
  background-size: cover;
  background-image: url('/static/images/desktop/icon/logo/logo_word_2x.png');
}

.topper .top__content .top__logo .logo__text span:first-child {
  font-size: 20px;
  color: #000;
  line-height: 27px;
}

.topper:not(.cd-scrolled) .top__content .top__logo .logo__text span:last-child {
  display: none;
}

.topper .top__content .top__minBtn {
  float: left;
  display: none;
}

.topper .top__content .top__nav {
  width: auto;
  height: 120px;
  float: right;
  position: relative;
  padding-right: 35px;
  transition: height 0.25s ease;
  overflow: visible;
}

/* flex 垂直置中；icon 在文字右側 */
.topper:not(.cd-scrolled) .top__content .top__nav > div {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  padding: 0 15px;
  height: 120px;
  font-size: 20px;
  position: relative;
  cursor: pointer;
  color: #000;
  overflow: visible;
}

.topper:not(.cd-scrolled) .top__content .top__nav > div .top__nav__name { order: 1; }

.topper:not(.cd-scrolled) .top__content .top__nav > div::before {
  order: 2;
  position: relative;
  top: auto;
  left: auto;
  margin: 0;
  width: 24px;
  height: 24px;
  content: '';
  display: block;
  background-size: cover;
}

.topper .top__content .top__nav > div:hover { color: #f08888; }

.topper .top__content .top__nav #tn2::before {
  background-image: url('/static/images/desktop/icon/topnav2.png');
}

/* Dropdown */
.topper .top__content .top__nav .top__nav__inner {
  display: none;
  padding: 40px 10px;
  z-index: 999;
  position: absolute;
  top: 122px; /* 120px navbar + 2px border-bottom */
  left: auto;
  right: 0;
  width: 725px;
  cursor: auto;
  background: #fff;
  border-bottom-left-radius: 20px;
  border-bottom-right-radius: 20px;
  box-shadow: 0 1px 3px 0 rgba(0,0,0,.2);
}

.topper .top__content .top__nav .top__nav__inner.showed {
  display: inline-block;
}

.topper .top__content .top__nav .top__nav__inner > .tni__left {
  width: 200px;
  float: left;
}

.topper .top__content .top__nav .top__nav__inner > .tni__left > img {
  width: 120px;
  height: 120px;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right { float: left; }

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul {
  width: auto;
  margin: -3px 30px 0;
  float: left;
  font-size: 17px;
  color: #595959;
  text-align: left;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul > li {
  margin-bottom: 15px;
  position: relative;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul a { color: #595959; }

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul a:hover {
  color: #f08888;
  text-decoration: underline;
}

/* Scroll-shrink */
.topper.cd-scrolled { height: 55px; }
.topper.cd-scrolled .top__content { height: 55px; min-width: auto; }
.topper.cd-scrolled .top__content .top__logo { height: 55px; margin-top: 0; padding: 6px 0 0 25px; }
.topper.cd-scrolled .top__content .top__logo .logo__icon { width: 40px; height: 40px; }
.topper.cd-scrolled .top__content .top__logo .logo__text { height: 40px; padding: 6px 0 0 8px; }
.topper.cd-scrolled .top__content .top__logo .logo__text span { display: none; }
.topper.cd-scrolled .top__content .top__nav { height: 55px; }
.topper.cd-scrolled .top__content .top__nav > div { padding-top: 18px; font-size: 0.95rem; }
.topper.cd-scrolled .top__content .top__nav > div::before { display: none; }
.topper.cd-scrolled .top__content .top__nav .top__nav__inner { top: 57px; }

} /* end desktop */

/* ── Mobile menu overlay ────────────────────────────────── */
@media (max-width: 1300px) {
  .fixedScroll { overflow: hidden; }

  body::before {
    z-index: 99;
    width: 100vw;
    height: 100vh;
    position: fixed;
    content: '';
    display: none;
    top: 0;
    left: 0;
    background: rgba(0,0,0,0.5);
    pointer-events: none;
  }

  body.fixedScroll::before { display: block; }
}

/* ── Tablet navbar (769px–1300px) ───────────────────────── */
@media (max-width: 1300px) and (min-width: 769px) {

.topper {
  z-index: 1009;
  position: fixed;
  top: 0;
  width: 100%;
  height: 100px;
  background: #fff;
  border-bottom: 2px solid #f08888;
}

.topper .top__content { width: 100%; height: 100px; }

.topper .top__content .top__logo {
  height: 90px;
  margin-top: 10px;
  margin-left: 15px;
}

.topper .top__content .top__logo .logo__icon {
  width: 232px;
  height: 80px;
  background-size: cover;
  background-image: url('/static/images/tablet/logo/logo_1x.png');
}

@media (-webkit-min-device-pixel-ratio: 1.5) and (max-width: 1300px) and (min-width: 769px),
       (max-width: 1300px) and (min-resolution: 144dpi) and (min-width: 769px) {
  .topper .top__content .top__logo .logo__icon {
    background-image: url('/static/images/tablet/logo/logo_2x.png');
  }
}

.topper .top__content .top__logo .logo__text { display: none; }

.topper .top__content .top__minBtn {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100px;
  height: 100px;
  background-color: transparent;
  cursor: pointer;
}

.topper .top__content .top__minBtn:before {
  content: '';
  display: block;
  width: 32px;
  height: 32px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  background-image: url('/static/images/desktop/icon/navhumburger.png');
}

.topper .top__content .top__minBtn.opened:before {
  background-image: url('/static/images/desktop/icon/navclose.png');
}

.topper .top__content .top__nav {
  position: fixed;
  float: none;
  background: #fff;
  border-top: 3px solid #f08888;
  top: 100px;
  right: 0;
  width: 500px;
  height: auto;
  max-height: 512px;
  padding: 0;
  transform: translate3d(502px, 0, 0);
  transition: none;
}

.topper .top__content .top__nav.opened {
  transform: translate3d(2px, 0, 0);
  transition: transform 300ms ease-in-out;
  overflow: scroll;
  overflow-x: hidden;
}

.topper .top__content .top__nav > div {
  width: 500px;
  height: 100%;
  padding: 0;
  border-bottom: 1px solid #dadada;
}

.topper .top__content .top__nav > div::after,
.topper .top__content .top__nav > div::before { display: none; }

.topper .top__content .top__nav > div:hover { background-image: none; }

.topper .top__content .top__nav > div .top__nav__name {
  width: 410px;
  padding: 25px 0 2px 88px;
  height: 40px;
  text-align: left;
  position: relative;
}

.topper .top__content .top__nav > div .top__nav__name::before {
  left: 45px;
  top: 14px;
  margin: 0;
  content: '';
  display: block;
  position: absolute;
  width: 40px;
  height: 40px;
  background-size: cover;
}

.topper .top__content .top__nav > #tn2 .top__nav__name::before {
  background-image: url('/static/images/desktop/icon/topnav2.png');
}

.topper .top__content .top__nav > div .top__nav__name:hover,
.topper .top__content .top__nav > div .top__nav__name.opened {
  background-image: url('/static/images/desktop/common/navBar/navHover_s.jpg');
}

.topper .top__content .top__nav > div .top__nav__name::after {
  right: 40px;
  top: 22px;
  content: '';
  display: block;
  position: absolute;
  width: 24px;
  height: 24px;
  transform: rotate(0deg);
  transition: transform 200ms;
  transform-origin: center center;
  background-image: url('/static/images/desktop/common/toggler.png');
}

.topper .top__content .top__nav > div .top__nav__name.opened::after {
  transform: rotate(180deg);
}

.topper .top__content .top__nav .top__nav__inner {
  position: static;
  display: none;
  box-shadow: none;
  border-radius: unset;
  border: 0;
  width: 100%;
}

.topper .top__content .top__nav .top__nav__inner > .tni__left { display: none; }

.topper .top__content .top__nav .top__nav__inner > .tni__right {
  width: 100%;
  margin-bottom: -1px;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul { width: 100%; margin-left: 0; }

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul > li {
  position: relative;
  width: 100%;
  height: 60px;
  padding-left: 40px;
  margin-bottom: 0;
  line-height: 60px;
  border-bottom: 1px solid #e0e0e0;
  list-style-type: disc;
  list-style-position: inside;
  color: #ccc;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul a {
  display: block;
  position: absolute;
  width: 100%;
  height: 60px;
  top: 0;
  left: 0;
  padding-left: 58px;
  color: #595959;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul a:hover {
  background: #f08888;
  color: #fff;
}

} /* end tablet */

/* ── Mobile navbar (≤ 768px) ────────────────────────────── */
@media (max-width: 768px) {

.topper {
  z-index: 1009;
  position: fixed;
  top: 0;
  width: 100%;
  height: 80px;
  background: #fff;
  border-bottom: 2px solid #f08888;
  box-shadow: none;
}

.topper .top__content {
  width: 100%;
  min-width: 320px;
  height: 80px;
}

.topper .top__content .top__logo {
  display: flex;
  align-items: center;
  height: 80px;
  margin-left: 6px;
}

.topper .top__content .top__logo .logo__icon {
  width: 194px;
  height: 70px;
  background-size: cover;
  background-image: url('/static/images/mobile/logo/logo_1x.png');
}

@media (-webkit-min-device-pixel-ratio: 1.5) and (max-width: 768px),
       (max-width: 768px) and (min-resolution: 144dpi) {
  .topper .top__content .top__logo .logo__icon {
    background-image: url('/static/images/mobile/logo/logo_2x.png');
  }
}

.topper .top__content .top__logo .logo__text { display: none; }

.topper .top__content .top__minBtn {
  z-index: 9999;
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  background-color: transparent;
  cursor: pointer;
}

.topper .top__content .top__minBtn:before {
  content: '';
  display: block;
  width: 28px;
  height: 28px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  background-image: url('/static/images/desktop/icon/navhumburger.png');
}

.topper .top__content .top__minBtn.opened:before {
  background-image: url('/static/images/desktop/icon/navclose.png');
}

.topper .top__content .top__nav {
  z-index: 9997;
  position: fixed;
  float: none;
  background: #fff;
  border-top: 3px solid #f08888;
  top: 80px;
  right: 0;
  width: 100%;
  max-width: 414px;
  height: auto;
  transform: translate3d(414px, 0, 0);
  transition: transform 300ms ease-in-out;
  padding: 0;
}

.topper .top__content .top__nav.opened {
  transform: translate3d(0px, 0, 0);
  overflow: scroll;
  overflow-x: hidden;
}

.topper .top__content .top__nav > div {
  width: 100%;
  max-width: 414px;
  height: 100%;
  padding: 0;
  border-bottom: 1px solid #dadada;
}

.topper .top__content .top__nav > div::after,
.topper .top__content .top__nav > div::before { display: none; }

.topper .top__content .top__nav > div:hover { background-image: none; }

.topper .top__content .top__nav > div .top__nav__name {
  width: calc(100% - 88px);
  padding: 22px 0 2px 88px;
  height: 35px;
  text-align: left;
  position: relative;
  font-size: 16px;
}

.topper .top__content .top__nav > div .top__nav__name::before {
  left: 45px;
  top: 7px;
  content: '';
  display: block;
  position: absolute;
  width: 40px;
  height: 40px;
  background-size: cover;
}

.topper .top__content .top__nav > #tn2 .top__nav__name::before {
  background-image: url('/static/images/desktop/icon/topnav2.png');
}

.topper .top__content .top__nav > div .top__nav__name:hover,
.topper .top__content .top__nav > div .top__nav__name.opened {
  background-image: url('/static/images/desktop/common/navBar/navHover_s.jpg');
}

.topper .top__content .top__nav > div .top__nav__name::after {
  right: 40px;
  top: 17px;
  content: '';
  display: block;
  position: absolute;
  width: 24px;
  height: 24px;
  transform: rotate(0deg);
  transition: transform 200ms;
  transform-origin: center center;
  background-image: url('/static/images/desktop/common/toggler.png');
}

.topper .top__content .top__nav > div .top__nav__name.opened::after {
  transform: rotate(180deg);
}

.topper .top__content .top__nav .top__nav__inner {
  position: static;
  display: none;
  box-shadow: none;
  border-radius: unset;
  border: 0;
  width: 100%;
}

.topper .top__content .top__nav .top__nav__inner > .tni__left { display: none; }

.topper .top__content .top__nav .top__nav__inner > .tni__right {
  width: 100%;
  margin-bottom: -1px;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul { width: 100%; margin-left: 0; }

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul > li {
  position: relative;
  width: calc(100% - 40px);
  height: 50px;
  padding-left: 40px;
  margin-bottom: 0;
  line-height: 50px;
  border-bottom: 1px solid #e0e0e0;
  list-style-type: disc;
  list-style-position: inside;
  color: #ccc;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul a {
  display: block;
  position: absolute;
  width: calc(100% - 58px);
  height: 50px;
  top: 0;
  left: 0;
  font-size: 15px;
  padding-left: 58px;
  color: #595959;
}

.topper .top__content .top__nav .top__nav__inner > .tni__right > ul a:hover {
  background: #f08888;
  color: #fff;
}

} /* end mobile */
