@media print{
@page{
  size: A4;
  size: landscape;
  margin: 0.5cm;
}
* {
  -webkit-print-color-adjust: exact !important;
  print-color-adjust:exact !important;
  color-adjust: exact;
}
  element
  { display: none; }
  element
  { page-break-inside: avoid; }
}
:root{
  --fs-s: 1.125rem;
  --fs-m: 1.5rem;
  --fs-lg: 1.75rem;
  --fs-xl: 2px;
  --fw-s: 400;
  --fw-m: 600;
  --fw-lg: 800;
  --ts-all: all 0.3s ease;
  --border-radius: 5px;
  --primary-color: #90cbfc;
  --secondary-color: #4caf50;
  --text-color: #333;
  --Neutral-color: #f4f4f4;
  --btn-shadow: 0 5px 20px rgb(51, 51, 51, .2);
  --translateY: translateY(-5px);
  --btn-hover: 0 10px 20px rgba(51, 51, 51, 0.3);
  --gap: 1rem;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
svg,image{ width:100% }
img,[src*="youtube"]{ max-width: 100%; }

body {
  font-family: "Microsoft JhengHei", sans-serif;
  background-color: #fffef7;
  color: #333;
  line-height: 1.6;
  letter-spacing: 0.125rem;
}
img{
  vertical-align: middle;
}
.card{
  background-color: transparent;
  border: none;
}
ul li,
button,
label,
input,
textarea,
legend {
  font-size: var(--fs-s);
}
input,
textarea{
  border: .1rem solid var(--primary-color);
  outline: none;
  border-radius: var(--border-radius);
  transition: var(--ts-all);
  padding: .5rem;
  color: var(--text-color);
  letter-spacing: 0.05rem;
}
input:focus,
textarea:focus{
  outline: none;
  border: .1rem solid #1f9aff;
  box-shadow: var(--btn-shadow);
}
/* Header */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 30px;
  background: #fff;
  border-bottom: 1px solid #ddd;
  position: fixed;
  width: 100%;
  height: 120px;
  z-index: 99;
  margin-top: -120px
}
.header .logo{
  width: min(100%, 500px);
  margin-top: 0;
}
.header .logo a{
  display: inline-block;
  max-height: 500px;
}
.header .logo img{
  height: 100%;
}
main{
  margin-top: 120px;      
}
/* 漢堡選單按鈕 */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 22px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.menu-toggle span {
  display: block;
  height: 3px;
  width: 100%;
  background: #333;
  border-radius: 2px;
  transition: all 0.3s ease;
}


.menu-toggle.active span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}
.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}
.menu-toggle.active span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* 導覽列 */
.nav {
  display: flex;
}

.nav a {
  margin-left: 20px;
  text-decoration: none;
  color: #333;
  font-size: var(--fs-s);
}

.nav a:hover {
  color: #4caf50;
}
/* title */
.container h1{
  text-align: center;
}
.attention-card,
.congratulation{
  max-width: 500px;
  margin: auto;
  background-color: #ffffff;
  border-radius: var(--border-radius);
  box-shadow: var(--btn-shadow);
}
.attention-card .title{
  text-align: center;
  background-color: #ffe9e0;
}
.attention-card img{
  width: 60px;
}
.lead{
  color: #ec4e09;
  text-align: center;
  margin: 0;
  padding: 1rem;
}
.reason{
  padding: 0 .5rem;
}
/* promotion-form */
.promotion-forms .item{
  display: flex;
  flex-direction: column;
  margin: 1rem 0;
}
.promotion-forms .item:nth-child(2){
  flex-grow: 1;
}
.checkbox-group{
  margin: 1rem 0;
}
.checkbox-group label{
  font-size: var(--fs-s);
  align-items:center;
  gap: var(--gap);
  cursor:pointer;
}
.promotion-forms .btn{
  width: 100%;
}
/* Flatpickr Calendar Custom Style */
.flatpickr-calendar {
  background: #fffaf3;
  border: 0.1rem solid #e0cfa9;
  box-shadow: 0 0.25rem 0.625rem rgba(0,0,0,0.1); 
  border-radius: var(--border-radius);
}

.flatpickr-day {
  color: #4a3f35;
  border-radius: var(--border-radius);
  border: none;
}

.flatpickr-day:hover {
  background: #f7e6c4;
  color: #000;
}

.flatpickr-day.today {
  background: #ffefcb;
  color: #000;
  font-weight: bold;
}

.flatpickr-day.selected {
  background: #ffbb9c;
  color: #fff;
  border: none;
}

.flatpickr-months .flatpickr-month {
  background: #fffaf3;
  color: #4a3f35;
  font-weight: bold;
}

.flatpickr-weekday {
  color: #a47c48; 
  font-weight: 600;
}

.flatpickr-current-month .flatpickr-monthDropdown-months:hover {
  background: rgb(179 51 51 / 5%);
}
/* upload-grid */
.upload-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}
.upload-slot {
  height: 300px;
  border: 0.1rem dashed #aaa;
  border-radius: 0.5rem;
  background: #f0efea;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  cursor: pointer;
  position: relative;
  gap: var(--gap);
}
.upload-grid .pic{
  height: 300px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.upload-grid .pic img,
.upload-grid .upload-icon img{
  max-height: 300px;
  border-radius: var(--border-radius);
}
.upload-grid .pic:after{
  content: "\F622";
  font-family: "bootstrap-icons";
  position: absolute;
  top: 0;
  right: .5rem;
  color: var(--primary-color);
  font-size: var(--fs-m);
  cursor: pointer;
}
.upload-label {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.upload-icon {
  color: #666;
  margin-bottom: 0.5rem;
}

.upload-text {
  color: #444;
  font-size: var(--fs-s);
  margin: 0;
}
.upload-grid textarea{
  width: 100%;
  background-color: transparent;
  margin-top: 1rem;
}
.upload-slot input[type="file"] {
  display: none;
}
.memo{
  background-color: #fff3d8;
  padding: 1rem 3rem;
}
/* Footer */
.footer {
  text-align: center;
  padding: 15px;
  margin-top: 30px;
}
@media (max-width: 600px) {  
  .footer {
    font-size: var(--fs-s);
    padding: 10px;
  }
}
/* 手機版樣式 */
@media (max-width: 930px) {
  .menu-toggle {
    display: flex;
  }

  .nav {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 120px;
    left: 0;
    background: #f6f6f7;
    width: 100%;
    height: 100vh;
    align-items: center;
    z-index: 1;
    opacity: 0; 
    transition: var(--ts-all);
  }

  .nav a {
    display: inline-block;
    width: 100%;
    border-bottom: 1px solid #ddd;
    padding: 10px 0;
    text-align: center;
    margin: 0;
    transition: var(--ts-all);
  }
  .nav a:hover{
    background-color: #ddd;
    color: #333;
  }
  .nav.active {
    display: flex;
    opacity: 1;
    }
  }
  h2{
  text-align: center;
  z-index: 1;
  margin: 0;
  color: var(--Neutral-color)
  }
  h3{
    font-size: var(--fs-m);
    font-weight: 700;
  }
  .btn-primary {
    display: inline-block;
    min-width: 240px;
    padding: 12px 0;
    border-radius: 50px;
    border: none;
    color: var(--text-color);
    box-shadow: var(--btn-shadow);
    background-color: #ffffff;
  }
  .btn-primary:hover{
    transform: var(--translateY);
    transition: var(--ts-all);
    box-shadow: var(--btn-hover);
  }
  .wrapper {
    max-width: 1440px;
    margin: 40px auto;
  }
  /* Footer */
  .footer {
    color: var(--text-color);
    text-align: center;
    padding: 15px;
    margin-top: 100px;
  }
  .info-sec{
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin: 20px 0 0 0 ;
  }
  .info .items,
  .info-sec .items{
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 10px 10px 0;
  }
  .info-sec .items .icon{
    width: 30px;
    height: 30px;
    margin-right: 16px;
  }
  .info-sec .items .text{
    text-align: left;
    white-space: nowrap;
  }
  .info a{
    text-decoration: none;
    color: #333;
    font-size: var(--fs-s);
    position: relative;
    margin: 0 10px;
  }
  .info a:hover{
    color: #4caf50;
    transition: var(--ts-all)
  }
  .info a + a:before{
    content: '｜';
    position: absolute;
    top: 0;
    left: -20px;
    color: #333;
  }
  .footer p{
    margin: 0;
  }
  .footer .copyright{
    padding: 12px 0 0 0;
    border-top: 1px solid var(--text-color)
  }

  @media (min-width: 320px) and (max-width: 993px){
    .upload-grid{
      grid-template-columns: repeat(2, 1fr);
    }
  }
  @media (min-width: 320px) and (max-width: 654px){    
    .header{
      padding: .5rem;
    }
  }
  @media (min-width: 320px) and (max-width: 571px){    
    .intro .text{
      margin: 20px 12px;
    }
    .upload-grid{
      grid-template-columns: repeat(1, 1fr);
      place-items: center;
    }
    .upload-grid .des{
      width: 280px;
    }
  }
  @media (min-width: 320px) and (max-width: 670px){
    .info-sec{
      grid-template-columns: repeat(1,1fr);
      place-items: center;
    }
    .info-sec .text{
      width: 277px;
    }
  }
  @media (min-width: 320px) and (max-width: 470px){
    .info a + a:before{
      left: -13px;
    }
    .info-sec .text{
      width: auto;
    }
    .info-sec .text p{    
      white-space: normal;
    }
    .info, .info-sec{
      justify-content: flex-start;
    }
  }
  @media (min-width: 670px) and (max-width: 890px){
    .info-sec{
      display: grid;
      grid-template-columns: repeat(2,1fr);
    }
  }


  h1{
    text-align: center;
    font-weight: var(--fw-lg);
    margin-top: 3rem
  }
  /* search input */
  .search-wrapper{
    margin-bottom: 3rem;
    text-align: center;
    display: grid;
    place-items: center;
  }
  .search-wrapper .container{
    position: relative;
    width: 25rem;
    transition: var(--ts-all);
  }
  .search-wrapper input{
    width: 25rem;
    background-color: transparent;
    transition: var(--ts-all);
    border-radius: 25px;
  }
  .search-wrapper input:focus{
    width: 35rem;
    border-width: 1.5px;
  }
  .search-wrapper:focus-within .container {
  width: 35rem;
}
  .search-wrapper .bi{
    width: 30px;
    height: 30px;
    position: absolute;
    right: 0;
    bottom: .5rem;
    color: var(--Neutral-color);
    font-size: var(--fs-s);
    background-color: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;    
  }
  .bi-search{
    color: #ffffff;
  }
  /* achievements */
.achievements {
  max-width: 1440px;
  margin: auto;
  display: grid;
  justify-content: center;
  grid-template-columns: repeat(3, 1fr);
  place-items: center;
}
.achievements .card {
  border-radius: var(--border-radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  height: 100%;
  position: relative;  
  cursor: pointer;
  margin: 0 1rem;
}
.achievements .card .pic{
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: var(--border-radius);
  transition: var(--ts-all);
}
.achievements .card:hover .pic{
  transform: var(--translateY);
}
.achievements .card .pic:after{
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.5));
  opacity: 0;
  transition: var(--ts-all);
}
.achievements .card:hover .pic:after{
  opacity: 1;
}
.achievements .card img {
  height: 300px;
  box-shadow: var(--btn-shadow);  
}

.achievements .card h2 {
  font-size: var(--fs-m);
  text-align: center;
  color: var(--text-color);
  text-shadow: 2px 3px 1px rgba(0,0,0,0.1);
  margin: 0 0 3rem 0;
}
.achievements .card p{
  height: 4.3rem;
  font-size: var(--fs-s);
  position: absolute;
  bottom: 5.5rem;
  background-color: rgba(255, 255, 255, .7);
  color: var(--text-color);
  margin: 0 1rem;
  padding: .5rem;
  border-radius: var(--border-radius);
  display: -webkit-box;        
  -webkit-box-orient: vertical; 
  -webkit-line-clamp: 2;       
  overflow: hidden;            
  text-overflow: ellipsis;
  word-break: break-word;
}

/* pagination */
.pagination {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
  border-radius: 50%;
  gap:var(--gap)
}
.pagination .page-numbers{
  display: flex;
  gap: var(--gap);
  background-color: var(--primary-color);
  padding: .5rem 1rem;
  border-radius: 50px;
}
.pagination button {
  width: 50px;
  height: 50px;
  border: none;
  padding: .5rem 1rem;
  border-radius: 50%;
  cursor: pointer;
  font-size: var(--fs-m);
  transition: var(--ts-all);  
  background: var(--primary-color);
}
.pagination button.active {
  background: rgba(255, 255, 255, .2);
  color: var(--Neutral-color);
  font-weight: var(--fw-m);
}
.pagination button:hover {
  background: rgba(255, 255, 255, .2);
  box-shadow: 2px 4px 5px rgba(139, 184, 226, 0.63);
  transform: translateY(-3px);
}
.pagination button:disabled{
  cursor: default;
  transform: translateY(0px);
}
.pagination img{
  margin-top: .8rem;
  width: 40px;
  height: 40px;
  transition: var(--ts-all);
  cursor: pointer;
}
.pagination img:hover{
  transform: var(--translateY)
}

@media (min-width: 767px) and (max-width: 990px){
  .achievements{
    display: grid;
    grid-template-columns: repeat(2,1fr);
  }
}
@media (min-width: 320px) and (max-width: 767px){
  .achievements{
    display: grid;
    grid-template-columns: repeat(1,1fr);
  }
}
@media (min-width: 360px) and (max-width: 480px){
  .search-wrapper input{
    padding: .5rem 2rem .5rem .5rem ;
  }
  .search-wrapper input,
  .search-wrapper .container{
    width: 20rem;
  }
  .search-wrapper input:focus,
  .search-wrapper:focus-within .container{
    width: 21rem;
  }
}
@media (min-width: 320px) and (max-width: 360px){
  .search-wrapper input{
    padding: .5rem 2rem .5rem .5rem ;
  }
  .search-wrapper input,
  .search-wrapper .container{
    width: 15rem;
  }
  .search-wrapper input:focus,
  .search-wrapper:focus-within .container{
    width: 16rem;
  }
  .pagination{
    gap: 0;
  }
}

/* swiper */
.swiper{ 
  width: 1200px; 
  max-width: 95%;
  margin: 0 auto;
  padding: 0;
}
.swiper-wrapper{ 
  align-items:center; 
}
.swiper-slide{
  width: 600px;
  border-radius: var(--border-radius);
  overflow: hidden;
}
.swiper-slide-active{
  transform: scale(1.08);
  transition: var(--ts-all);
  z-index: 2;
  box-shadow: var(--btn-shadow);
}
.buttons{
  position: relative;
  top: -4rem;
  margin: auto;
  width: 150px;
  height: 50px;
}
.swiper-slide-prev,
.swiper-slide-next{
  opacity: 0.8;
  transform: scale(.94);
}
.swiper-pagination {
bottom: 0rem !important;
left: 0;
height: 100px;
text-align: center;
}
.swiper-pagination-bullet-active{
  background-color: var(--primary-color);
  transform: scale(1.5);
}
.swiper-button-prev,
.swiper-button-next {
  width: 50px;
  height: 50px;
  background-color: var(--primary-color);   
  border-radius: var(--border-radius);
  color: var(--Neutral-color);
  z-index: 10;
  margin-top: 0rem !important;
  bottom: 0 !important;
  top: 0 !important;
}

.swiper-button-prev {
  left: 0% !important;
}
.swiper-button-next {
  right: 0% !important;
}
.swiper-button-next svg,
.swiper-button-prev svg {
  width: 40px;
  height: 40px;
}
.description{
  text-align: center;
  margin-top: 1rem;
}
/* glightbox */

/* socialize */
.socialize{
  margin: 0 auto 0;
}
.socialize .container{
  max-width: 780px;
  display: flex;
  justify-content: end;
}
.socialize p{
  font-size: var(--fs-s);
}
.socialize .items{
  display: flex;
  margin-left: 1rem;
  gap: var(--gap);
}
.socialize .items img{
  width: 40px;
  height: 40px;
  background-color: var(--primary-color);
  border: 1px solid var(--Neutral-color);
  border-radius: var(--border-radius);
  cursor: pointer;
  transition:var(--ts-all);
}
.socialize .item:hover img{
  transform: var(--translateY);
  box-shadow: var(--btn-shadow);
}
/* content */
.content{
  display: flex;
  justify-content: center;
}
.content-container{
  max-width: 780px;
  margin: 0 1rem
}
.content h2{
  font-size:var(--fs-m);
  color: var(--text-color);
  border-bottom: 1px solid #aaaaaa;
  padding: 1rem 0;
}
.content .text{
  font-size: var(--fs-m);
  margin-top: 1rem; 
}
.content .des{
  font-size: var(--fs-m);
}
@media (min-width: 320px) and (max-width: 520px){
  .content .text{
    margin: 1rem auto;
    width: 230px;
  }
}

/* list */
.banner img{
  width: 100%;
}
.title{
  text-align: center;
}
.title .p-b{
  color: #4D8BAD;
  font-weight: var(--fw-lg);
  text-decoration: none;
}
.title .p-r{
  color: #FB1212;
  font-weight: var(--fw-lg);
  text-decoration: none;
}
/* tabs */
.tabs {
  max-width: 1000px;
  margin: 2rem auto;  
}

/* Tabs Navigation */
.tabs-nav {
  position: relative;
  display: flex;
  justify-content: center;
  background: var(--primary-color);
  padding: 0.375rem;
  border-radius: 50px;
  margin-bottom: 2rem;
  isolation: isolate; /* Create new stacking context */
}

/* Tab Buttons */
.tab-btn {
  flex: 1;
  all: unset;
  position: relative;
  padding: 0.5rem 1rem;
  font-size: var(--fs-s);
  font-weight: var(--fw-m);
  color: var(--text-color);
  border-radius: 50px;
  cursor: pointer;
  transition: color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: center;
  white-space: nowrap;
  z-index: 1;
  margin: 0 .5rem;
}
.tabs .tab-icon{
  display: inline-block;
  width: 30px;
  visibility: hidden;
  transform: var(--translateY);
  transition: transform 0.6s ease, opacity 0.6s ease;
}
.tabs .active .tab-icon{
  visibility: visible;
  transform: translateY(0);
  vertical-align: bottom;
  color: var(--Neutral-color)
}
.tab-btn:hover,
.tabs .tab-btn:hover .tab-icon {
  color: #ffffff;
}
.tab-btn[aria-selected="true"] {
  color: #ffffff;
}
.tabs .text{
  width: 520px;
  margin-left: 2rem;
}
.tabs .text .t-red{
  color: #e23535
}
.tabs .text h1,
.tabs .text p{
  margin: 0;
  text-align: left;
}
/* Moving Indicator */
.tabs-indicator {
  position: absolute;
  top: 0.375rem;
  bottom: 0.375rem;
  left: 0;
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.281);
  transition: 
    transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
    width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  z-index: 0;
  will-change: transform, width;
}

/* Tab Panels */
.tab-panel {
  padding: 2rem;
  background: transparent;
  display: none;
  transform-origin: top;
  animation: slideIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.tab-panel[aria-hidden="false"] {
  display: block;
}

/* Animations */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-8px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}


/* Content styling */
.tab-panel .container{
  max-width: 1440px;
  margin: auto;
}
.tab-panel .item{
  display: flex;
  flex-grow: 2;
  align-items: center;
}
.tab-panel .item + .item{
  margin-top: 2rem;
}
.tab-panel .pic{
  width: 200px;
}
.tab-panel .text h3{
  text-align: left;
}
.tab-panel .txt{
  display: inline-flex;
  align-items: center;
  gap: var(--gap);
  align-items: flex-start;
}
.tab-panel .txt img,
.tab-panel .txt-grid img{
  width: 30px;
  border-radius: var(--border-radius);
}
.tab-panel .txt-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px,1fr));
  gap: var(--gap);
  flex-wrap: wrap;
}


@media (min-width: 320px) and (max-width: 767px){
  .tabs-nav{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    background-color: transparent;
    gap:var(--gap)
  }
  .tab-btn{
    background-color: var(--primary-color);
  }
  .tabs .tab-icon{
    width: 30px;
    visibility: visible;
    color: var(--text-color);
    transform: var(--translateY);
    transition: color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  }
}
@media (min-width: 320px) and (max-width: 400px){
  .tabs-nav{
    grid-template-columns: repeat(2, 1fr);
  } 
}
@media (min-width: 680px) and (max-width: 850px){
  .tab-panel .txt-grid{
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (min-width: 320px) and (max-width: 680px){
  .tab-panel .txt-grid{
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 320px) and (max-width: 480px){
  .tab-panel .item{
    flex-direction: column;
  }
  .tabs .text{
    width: 288px;
  }
}

/* 我要領獎 */
.congratulation {
  padding: 1rem;
  margin: 1rem auto 4rem;
}
.congratulation .pic{
  width: 100%;
  text-align: center;
}
.congratulation .pic img{
  width: 80px;
}
.congratulation h2{
  color: #FB1212;
  margin: 2rem 0;
}
.congratulation p{
  text-align: center;
}
.award-des{
  border: 1px solid var(--primary-color);
  border-radius: var(--border-radius);
  padding: 1rem;
}
.award-des li{
  margin: 1rem 0 1rem 1rem;
}
.input-info{
  max-width: 500px;
  margin: auto;
  padding: 0 1rem;
}
.input-info .input-container{
  display: flex;
  margin: 1rem 0;
  align-items: center;
}
.input-container p{
  white-space: nowrap;
  margin: 0 .5rem 0 0;;
}
.input-info .input-container input{
  width: 100%;
}
.input-info .btn{
  width: 100%;
}
.input-container .btn{
  padding: .5rem;
  color: var(--Neutral-color);
  transition: filter 0.3s
}
.input-container .btn:hover{
  filter: brightness(90%);
}
.input-container .btn{
  background-color: #2600ff;
}
.input-container .btn + .btn{
  background-color: #1f9aff;
  margin: 0 .5rem;
}
.input-container .btn:last-child{
  background-color: #f32525;
}
@media (min-width: 320px) and (max-width: 576px){
  .input-info .input-container:not(:nth-child(4)){
    display: block;
  }
}