/* --- 1. CẤU HÌNH CHUNG (RESET & FONTS) --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --color-red-dark: #8B0000;
  --color-red-bright: #dc2626;
  --color-yellow: #FCD34D;
  --color-beige: #e8dcc5;
  --color-brown: #78350f;
  --font-tet: 'Coiny', cursive;
  --font-body: 'Comfortaa', cursive;
  --font-script: 'Dancing Script', cursive;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-red-dark);
  /* Họa tiết nền */
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%239c1414' fill-opacity='0.4'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  display: flex;
  justify-content: center;
  min-height: 100vh;
  color: #333;
}

/* --- 2. KHUNG ĐIỆN THOẠI (CONTAINER) --- */
.app-container {
  width: 100%;
  max-width: 500px;
  /* Kích thước giống điện thoại */
  background-color: var(--color-red-dark);
  position: relative;
  min-height: 100vh;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  border-left: 2px solid #5a0202;
  border-right: 2px solid #5a0202;
  padding-bottom: 80px;
  /* Chừa chỗ cho footer */
  overflow: hidden;
}

/* --- 3. TRANG TRÍ NỀN (MÂY, SAO) --- */
.bg-decoration {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.cloudUL {
  position: absolute;
  top: 0;
  left: 0;
  width: 45%;
  height: auto;
  animation: float 5s infinite;
}

.cloudUR {
  position: absolute;
  top: 0;
  right: 0;
  width: 45%;
  height: auto;
  animation: float 4s infinite;
}

.cloudBR {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 35%;
  height: auto;
  animation: float 4s infinite;
}

.cloudBL {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 35%;
  height: auto;
  animation: float 5s infinite;
}

.phaohoaDuoi {
  position: absolute;
  bottom: 2.5%;
  left: 42%;
  width: 15%;
  height: auto;
}

.DAOTRAI {
  position: absolute;
  bottom: 20%;
  left: 0;
  width: 25%;
  height: auto;

}

.DAOPHAI {
  position: absolute;
  bottom: 40%;
  right: 0;
  width: 25%;
  height: auto;
}

.PHAOHOAGIUA {
  position: absolute;
  bottom: 45%;
  left: 42%;
  width: 15%;
  height: auto;
}

.PHAOHOACANH {
  position: absolute;
  top: 10%;
  right: 1.5%;
  width: 20%;
  height: auto;
  animation: pulse 3s ease-in-out infinite;

}

.PHAOHOATREN {
  position: absolute;
  top: 0;
  right: 42%;
  width: 15%;
  height: auto;
  animation: pulse 2s infinite;
}

.NGUA {
  position: absolute;
  bottom: 15%;
  right: 35%;
  width: 15%;
  height: auto;
}

.HOATRAI {
  position: absolute;
  top: 12%;
  left: 1.5%;
  width: 20%;
  height: auto;

  animation: spin 4s ease-in-out infinite;
}

.HOAPHAI {
  position: absolute;
  top: 25%;
  right: 0;
  width: 15%;
  height: auto;

}

.LIXI {
  position: absolute;
  top: 25%;
  left: 0;
  width: 15%;
  height: auto;

}

.cloud {
  position: absolute;
  color: var(--color-yellow);
  opacity: 0.2;
  font-size: 2rem;
}

.cloud-1 {
  top: 40px;
  left: -10px;
  font-size: 2.5rem;
}

.cloud-2 {
  top: 80px;
  right: -10px;
  font-size: 3rem;
}

.star {
  position: absolute;
  top: 150px;
  left: 40px;
  color: #fde047;
  animation: pulse 2s infinite;
}

.fan {
  position: absolute;
  bottom: 40px;
  right: 40px;
  color: #ef4444;
  opacity: 0.3;
  font-size: 4rem;
  animation: spin 10s linear infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }
}

@keyframes spin {

  0%,
  100% {
    transform: rotate(10deg);
  }

  50% {
    transform: rotate(-10deg);
  }
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-5px);
  }
}

@keyframes floatWithSpin {

  0%,
  100% {

    transform: rotate(0deg) translateY(0);
  }

  50% {

    transform: translateY(-10px) rotate(2deg);

  }
}

/* --- 4. HEADER & NÚT ĐIỀU HƯỚNG --- */
.header-nav {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  padding: 20px 16px;
}

.btn-nav {
  background-color: var(--color-yellow);
  color: var(--color-red-dark);
  border: 2px solid var(--color-red-dark);
  padding: 8px 16px;
  border-radius: 20px;
  font-weight: bold;
  font-size: 0.8rem;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s;
}

.btn-nav:hover {
  transform: scale(1.05);
  background-color: #fce786;
}

/* --- 5. BANNER LOGO --- */
.banner-section {
  position: relative;
  z-index: 10;
  text-align: center;
  margin-top: 10px;
  margin-bottom: 30px;
  animation: floatWithSpin 4s ease-in-out infinite;
}

.title-line-1 {
  font-family: var(--font-script);
  font-size: 3rem;
  color: white;
  line-height: 1;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.title-line-2 {
  font-family: var(--font-script);
  font-size: 2.5rem;
  color: white;
  margin-top: -5px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.highlight {
  color: var(--color-yellow);
}

.year-badge {
  display: inline-block;
  background: white;
  color: var(--color-red-dark);
  padding: 4px 16px;
  border-radius: 20px;
  font-family: var(--font-tet);
  font-size: 1.2rem;
  border: 2px solid var(--color-yellow);
  margin-top: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.lion-icon {
  font-size: 4rem;
  display: block;
  margin-top: 10px;
  filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.3));
}

/* --- 6. TAB SWITCHER (NÚT CHUYỂN TAB) --- */
.tab-controls {
  display: flex;
  gap: 10px;
  padding: 0 16px;
  margin-bottom: 20px;
  position: relative;
  z-index: 10;
}

.tab-btn {
  flex: 1;
  padding: 10px;
  border-radius: 12px;
  font-family: var(--font-tet);
  text-transform: uppercase;
  font-size: 0.9rem;
  border: 2px solid #b45309;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.3s;
}

#btn-xuki {
  margin-left: 10%;
}

#btn-loc {
  margin-right: 10%;
}


.tab-btn.active {
  background-color: var(--color-yellow);
  color: var(--color-brown);
  transform: scale(1.05);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.tab-btn.inactive {
  background-color: #991b1b;
  color: #fbbf24;
  opacity: 0.8;
}

/* --- 7. NỘI DUNG CHÍNH (CARD) --- */
.content-area {
  padding: 0 16px;
  position: relative;
  z-index: 10;
}

.hidden {
  display: none !important;
}

.card-frame {

  border-radius: 20px;
  background-image: url(images/POPUP\ 2.png);
  background-size: cover;
  padding: 100px 30px 80px 30px;
  margin-bottom: 50px;
  /* Padding dưới lớn để chừa chỗ cho nút */
  position: relative;
  box-shadow: 0 10px 15px rgba(0, 0, 0, 0.3);
  color: #5d2e08;
}

/* Góc trang trí của khung */
.corner {
  position: absolute;
  width: 15%;
  height: 15%;
  max-height: 90px;
  pointer-events: none;
}

.tl {
  top: 100px;
  left: 8px;
  border-right: none;
  border-bottom: none;
  border-radius: 8px 0 0 0;
}

.tr {
  top: 100px;
  right: 8px;
  border-left: none;
  border-bottom: none;
  border-radius: 0 8px 0 0;
}

.bl {
  bottom: 8px;
  left: 8px;
  border-right: none;
  border-top: none;
  border-radius: 0 0 0 8px;
}

.br {
  bottom: 8px;
  right: 8px;
  border-left: none;
  border-top: none;
  border-radius: 0 0 8px 0;
}

.card-title {
  font-family: var(--font-tet);
  font-size: x-large;
  text-align: center;
  color: #9c2816;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.card-desc {
  text-align: justify;
  font-size: 0.9rem;
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.5;
}

/* --- 8. FORM ĐIỀN THÔNG TIN --- */
.form-box {
  background-color: var(--color-beige);

  padding: 15px;
  border-radius: 12px;
  border: 1px solid #c4a484;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.form-group {
  margin-bottom: 12px;

}

.form-label {
  display: block;

  font-size: 0.8rem;
  font-weight: bold;
  margin-bottom: 4px;
}

.required {
  color: red;
}

.input-text {
  width: 100%;
  padding: 8px;
  border: 1px solid #ca8a04;
  border-radius: 4px;
  font-size: 0.9rem;
  outline: none;
}

.input-text1 {
  width: 100%;
  resize: none;
  padding: 8px;
  border: 1px solid #ca8a04;
  border-radius: 4px;
  font-size: 0.9rem;
  outline: none;
}

.input-text:focus {
  border-color: red;
  box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.2);
}

.btn-map {
  background-color: #3b82f6;
  color: white;
  border: none;
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 0.8rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

/* --- 9. NÚT HÀNH ĐỘNG LỚN (FLOAT BUTTON) --- */
.float-btn-container {
  position: absolute;
  bottom: -25px;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
}

.btn-action {
  background-color: var(--color-red-bright);
  color: var(--color-yellow);
  border: 2px solid var(--color-yellow);
  padding: 12px 10px;
  border-radius: 20px;
  font-family: var(--font-tet);
  font-size: 1rem;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.2s;
  width: 60%;
  min-width: 240px;
  justify-content: center;
}

.LogoBTN {
  animation: spin 4s ease-in-out infinite;
}

.btn-action:hover {
  transform: scale(1.05) translateY(-2px);
  background-color: #b91c1c;
}

.btn-note {
  color: var(--color-yellow);
  font-size: 0.7rem;
  font-weight: bold;
  margin-top: 5px;
  text-shadow: 0 2px 2px rgba(0, 0, 0, 0.5);
}

/* --- 10. MODAL (POPUP) --- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: #FFF8E7;
  width: 90%;
  max-width: 400px;
  border-radius: 16px;
  padding: 20px;
  position: relative;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  border: none;
  background: none;
  font-size: 1.5rem;
  color: #991b1b;
  cursor: pointer;
}

/* List styles in modal */
.list-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}

.list-tab-btn {
  flex: 1;
  padding: 5px;
  border-radius: 4px;
  cursor: pointer;
  border: none;
  font-weight: bold;
  font-size: 0.8rem;
}

.list-tab-btn.active {
  background: #dc2626;
  color: #fef08a;
}

.list-tab-btn.inactive {
  background: #fef08a;
  color: #991b1b;
  border: 1px solid #991b1b;
}

.list-items {
  list-style: none;
  overflow-y: auto;
  flex: 1;
}

.list-item {
  background: white;
  padding: 10px;
  margin-bottom: 8px;
  border-radius: 6px;
  border: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Result Lucky Draw */
.lucky-result {
  text-align: center;
}

.prize-box {
  font-family: var(--font-tet);
  color: #dc2626;
  font-size: 1.5rem;
  background: #fef08a;
  padding: 15px;
  border-radius: 10px;
  border: 2px solid #dc2626;
  margin: 15px 0;
}

/* --- 11. ADMIN PANEL STYLES --- */
.admin-table-container {
  overflow-x: auto;
  margin-bottom: 20px;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  min-width: 500px;
}

.admin-table th,
.admin-table td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: left;
}

.admin-table th {
  background-color: #f2f2f2;
  color: #333;
  font-weight: bold;
}

.admin-table tr:nth-child(even) {
  background-color: #f9f9f9;
}

.btn-export {
  background: #10b981;
  color: white;
  border: none;
  padding: 5px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.75rem;
  margin-bottom: 5px;
}

/* Footer stars 
.footer-stars {
  text-align: center;
  margin-top: 50px;
  color: rgba(252, 211, 77, 0.5);
  font-size: 1.5rem;
}
  */