/* 1. Fade-in Up Animation for Sections */
@keyframes fadeUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Apply fade-up animation to visible sections */
section {
  animation: fadeUp 1.1s ease-out forwards;
}



/* 2. Glowing Button Animation */
@keyframes glowPulse {
  0% { box-shadow: 0 0 0px rgba(255, 102, 0, 0.4); }
  50% { box-shadow: 0 0 16px rgba(255, 102, 0, 0.8); }
  100% { box-shadow: 0 0 0px rgba(255, 102, 0, 0.4); }
}

.btn:hover {
  animation: glowPulse 0.9s infinite;
}


/* 3. Optional: Smooth fade for any element */
.fade-in {
  opacity: 0;
  animation: fadeUp 1.2s ease-out forwards;
}


/* 4. Accessibility: Disable animations for motion-sensitive users */
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}

  /* 1.*/

h1, h2, h3 {
  font-family: "Poppins", sans-serif !important;
  font-weight: 700 !important;
  letter-spacing: 1px !important;
  color: #222 !important;
}

p {
  font-size: 1.05rem !important;
  line-height: 1.8rem !important;
  color: #333 !important;
}
/* 2. */
a {
  transition: 0.2s ease;
}

a:hover {
  color: #ff6600 !important;
  text-decoration: none !important;
}

.btn {
  transition: 0.25s ease-in-out !important;
}

.btn:hover {
  background-color: #9b5e36 !important;
  color: #fff !important;
  transform: scale(1.05);
}
/* 3. */
.section-padding {
  padding-top: 90px !important;
  padding-bottom: 90px !important;
}


.card, .portfolio-card {
  padding: 20px !important;
  border-radius: 12px !important;
  box-shadow: 0px 4px 18px rgba(0, 0, 0, 0.07) !important;
}

/* 4. */
.header {
  background: #ffffffee !important;
  backdrop-filter: blur(6px) !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06) !important;
}

.header .navmenu a {
  font-weight: 600 !important;
}

.header .navmenu a:hover {
  color: #9b5e36 !important;
}


.portfolio-card {
  border-radius: 14px !important;
  overflow: hidden !important;
  background: #fff !important;
  transition: 0.3s ease !important;
}

.portfolio-card:hover {
  transform: translateY(-5px) !important;
  box-shadow: 0px 8px 30px rgba(0, 0, 0, 0.12) !important;
}

.portfolio-card h3 {
  font-weight: 600 !important;
  color: #222 !important;
}

.portfolio-card .category {
  color: #9b5e36 !important;
  font-weight: 500 !important;
}
/* 5. */
ul.custom-list,
ol.custom-olist {
  margin-left: 0;
  padding-left: 0;
}

ul.custom-list li {
  position: relative;
  list-style: none;
  padding-left: 10px;
  margin-bottom: 5px;
  font-size: 1.05rem;
}

ul.custom-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  width: 10px;
  height: 10px;
  background: #9b5e36;
  border-radius: 50%;
}

ul.custom-list ul li::before {
  background: #ff6600;
}

ol.custom-olist {
  counter-reset: item;
}

ol.custom-olist li {
  list-style: none;
  counter-increment: item;
  padding-left: 10px;
  margin-bottom: 10px;
  position: relative;
  font-size: 1.05rem;
}

ol.custom-olist li::before {
  content: counter(item);
  position: absolute;
  left: 0;
  top: 2px;
  width: 22px;
  height: 22px;
  background: #9b5e36;
  color: #fff;
  font-size: 0.85rem;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: 600;
}

/* 6.  */

table.custom-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
  margin-top: 20px;
  background: #fff;
}

table.custom-table thead {
  background: #9b5e36;
  color: #fff;
}

table.custom-table thead th {
  padding: 14px;
  text-align: left;
  font-weight: 600;
}
/* Zebra stripes */
table.custom-table tbody tr:nth-child(even) {
  background: #f7f2ed;
}

table.custom-table tbody tr:hover {
  background: #f1e4d8;
  transition: 0.2s ease-in-out;
}

table.custom-table td {
  padding: 12px;
  color: #333;
}

table.custom-table .num {
  text-align: right;
}

#loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: white;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

/* Spinner Animation */
.spinner {
  width: 55px;
  height: 55px;
  border: 6px solid #ddd;
  border-top-color: #9b5e36;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.animated-gradient {
  background: linear-gradient(135deg, #d4c8c0, #5e4534, #ea8233);
  background-size: 400% 400%;
  animation: gradientMove 12s ease infinite;
}

@keyframes gradientMove {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Smooth scale + glow on cards */
.card:hover,
.portfolio-card:hover {
  transform: translateY(-12px) scale(1.03);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.18) !important;
  transition: 0.35s ease;
}

/* Subtle underline grow for links */
a:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}


.shape {
  position: absolute;
  background: rgba(255, 102, 0, 0.25);
  border-radius: 50%;
  animation: floatShape 8s ease-in-out infinite;
  z-index: -1;
}

.shape.small {
  width: 30px;
  height: 30px;
  animation-duration: 9s;
}

.shape.medium {
  width: 55px;
  height: 55px;
  animation-duration: 11s;
}

.shape.large {
  width: 90px;
  height: 90px;
  animation-duration: 13s;
}

@keyframes floatShape {
  0%   { transform: translateY(0) translateX(0); opacity: 0.4; }
  50%  { transform: translateY(-35px) translateX(20px); opacity: 0.9; }
  100% { transform: translateY(0) translateX(0); opacity: 0.4; }
}
/* ===========================
   LAB 11 — Form Validation & Rating
   =========================== */

.error {
  color: red;
  font-size: 0.85rem;
  margin-left: 10px;
}

.result-box {
  padding: 20px;
  border-radius: 8px;
  display: none;
  margin-top: 20px;
  font-size: 1.1rem;
}

.result-success { background: #fffbc1; }      /* Yellow */
.result-warning { background: #ffe8a3; }
.result-danger  { background: #ffb8b8; }

/* Popup (notification) */
.popup-message {
  position: fixed;
  top: 20px;
  right: 20px;
  background: #4CAF50;
  color: white;
  padding: 12px 20px;
  border-radius: 6px;
  font-size: 16px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease-in-out;
  z-index: 9999;
}

.popup-message.show {
  display: block;
  opacity: 1;
}
/* =========================================================
   LAB 12 – MEMORY GAME STYLES
   ========================================================= */

.memory-board-wrapper {
  display: flex;
  justify-content: center;
}

.memory-grid {
  display: grid;
  gap: 12px;
  justify-content: center;
  margin-bottom: 1.5rem;
}

/* Easy: 4 columns × 3 rows */
.memory-grid-easy {
  grid-template-columns: repeat(4, minmax(70px, 1fr));
}

/* Hard: 6 columns × 4 rows */
.memory-grid-hard {
  grid-template-columns: repeat(6, minmax(55px, 1fr));
}

.memory-card {
  width: 100%;
  aspect-ratio: 3 / 4;           /* keeps cards rectangular */
  perspective: 800px;
  cursor: pointer;
}

.memory-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.4s;
  transform-style: preserve-3d;
}

.memory-card.flipped .memory-card-inner,
.memory-card.matched .memory-card-inner {
  transform: rotateY(180deg);
}

.memory-card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 600;
}

/* Back side (hidden content) */
.memory-card-back {
  background: #ffffff;
  border: 2px solid #e0e0e0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  transform: rotateY(180deg);
}

/* Front side (logo / question mark) */
.memory-card-front {
  background: linear-gradient(135deg, #ffb26b, #ff7b54);
  color: #fff;
  border: 2px solid #ff9966;
}

/* When card is matched, make it a bit dimmer */
.memory-card.matched .memory-card-back {
  background: #e7ffe7;
  border-color: #8bc34a;
}

/* Stats small card */
.memory-stats {
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.04);
  font-size: 0.95rem;
}
/* ===== LAB 12 OPTIONAL – TIMER + BEST SCORE ===== */

#timerDisplay {
  font-weight: 600;
  color: #ff7b54;
}

#bestScore {
  font-weight: 600;
  color: #2e7d32;
}

/* Skills Section */
.skill-box {
  background: #fff;
  border: 1px solid #e9ecef;
  border-radius: 12px;
  padding: 24px;
  height: 100%;
  transition: box-shadow 0.3s ease;
}

.skill-box:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.skill-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
  gap: 12px;
}

.skill-box h3 {
  font-size: 15px;
  font-weight: 600;
  color: #2c2c2c;
  margin: 0;
  line-height: 1.4;
}

.skill-val {
  font-size: 14px;
  font-weight: 600;
  color: #e8845a;
  white-space: nowrap;
  margin-top: 2px;
}

.skill-box p {
  font-size: 13px;
  color: #6c757d;
  line-height: 1.6;
  margin-bottom: 14px;
}

.skill-box .progress {
  height: 6px;
  border-radius: 4px;
  background-color: #e9ecef;
  margin: 0;
}

.skill-box .progress-bar {
  background-color: #e8845a;
  border-radius: 4px;
  transition: width 1s ease-in-out;
}