/* --- Global Reset --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

/* --- Body --- */
body {
  background: linear-gradient(180deg, #ffe6f2 0%, #f3e6ff 100%);
  color: #333;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  transition: background 0.4s, color 0.4s;
}

/* --- Header --- */
.site-header {
  text-align: center;
  background: linear-gradient(90deg, #f9d1e9, #e2c8ff);
  padding: 1.5rem 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  border-bottom: 3px solid #f7cbe2;
  transition: background 0.4s, color 0.4s;
}

.site-header h1 {
  color: #504b92;
  font-size: 1.9rem;
  letter-spacing: 1px;
}

.site-header p {
  font-size: 1rem;
  color: #6d4b74;
  margin-top: 0.3rem;
}

/* --- Navigation --- */
nav {
  background-color: #fff;
  border-bottom: 2px solid #ddd;
  box-shadow: 0 1px 5px rgba(0,0,0,0.05);
}

#navList {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 50px;
  padding: 15px 0;
}

#navList a {
  text-decoration: none;
  color: #9f85e2;
  font-weight: 600;
  transition: all 0.2s ease;
}

#navList a:hover {
  text-decoration: underline;
  color: #6383c7;
}


/* --- Main Layout --- */
.main-container {
  display: flex;
  flex: 1;
  padding: 1.5rem;
  gap: 1.5rem;
  flex-wrap: wrap;
  transition: background 0.4s, color 0.4s;
}

        
/* --- Sidebar --- */
.sidebar {
  width: 260px;
  background: linear-gradient(180deg, #fff 0%, #fff5fb 100%);
  border-radius: 20px;
  padding: 1.2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  transition: all 0.4s ease;
}

.profile-card {
  text-align: center;
}

.profile-card img {
  border-radius: 50%;
  border: 3px solid #f8b3d0;
  box-shadow: 0 4px 8px rgba(248, 179, 208, 0.4);
  width: 120px;
  height: 120px;
  object-fit: cover;
}

.profile-card h3 {
  margin-top: 0.6rem;
  color: #b84d94;
  font-size: 1.1rem;
}

.profile-card p {
  font-size: 0.9rem;
  color: #6d4b74;
}

/* --- Sidebar Buttons --- */
.activity-menu h2 {
  margin: 1rem 0 0.5rem;
  font-size: 1.05rem;
  color: #b84d94;
  border-bottom: 1px solid #f0c6de;
  text-align: center;
  padding-bottom: 0.2rem;
}

.activity-menu button {
  width: 100%;
  padding: 0.5rem;
  margin: 0.3rem 0;
  border: none;
  border-radius: 10px;
  background-color: #fbd6eb;
  color: #5a305b;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.25s ease;
}

.activity-menu button:hover {
  background-color: #eec9ff;
  transform: translateY(-2px);
}

/* --- Content Area --- */
.content {
  flex: 1;
  background: #fff;
  border-radius: 20px;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: background 0.4s, color 0.4s;
}

/* --- About Section (Separated Box) --- */
.about-section {
  background-color: #fff8fc;
  border: 2px solid #f8c8e0;
  border-radius: 15px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 10px rgba(240, 180, 210, 0.25);
  transition: all 0.3s ease;
}

.about-section:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(240, 180, 210, 0.4);
}

.about-section h2 {
  color: #b84d94;
  margin-bottom: 0.8rem;
  border-left: 5px solid #f4a4cb;
  padding-left: 10px;
}

.about-section p {
  line-height: 1.6;
  color: #5a305b;
  margin-bottom: 0.6rem;
}

.exercise-output {
  background-color: #fff8fc;
  border: 2px solid #f8c8e0;
  border-radius: 15px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 10px rgba(240, 180, 210, 0.25);
  transition: all 0.3s ease;
}



.exercise-output h2 {
  color: #b84d94;
  margin-bottom: 0.8rem;
  border-left: 5px solid #f4a4cb;
  padding-left: 10px;
}

.exercise-output p {
  line-height: 1.6;
  color: #5a305b;
  margin-bottom: 0.6rem;
}

/* --- Exercise Output Container (NEW separated card) --- */
.exercise-output {
  background-color: #fff8fc;
  border: 2px solid #f6c9e3;
  border-radius: 15px;
  padding: 1.5rem;
  box-shadow: 0 2px 10px rgba(240, 180, 210, 0.25);
  transition: all 0.3s ease;
  margin-top: 1.5rem;
}

.exercise-output:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(240, 180, 210, 0.4);
}

.exercise-output h3 {
  color: #b84d94;
  margin-bottom: 1rem;
}

/* Inputs & Buttons inside Exercise Output */
.exercise-output input[type="text"],
.exercise-output input[type="number"] {
  width: 100%;
  max-width: 240px;
  padding: 0.6rem;
  border: 1px solid #f3bde3;
  border-radius: 8px;
  outline: none;
  margin-top: 0.4rem;
  background-color: #fffafc;
}

.exercise-output button {
  background-color: #f3bde3;
  color: #333;
  border: none;
  border-radius: 8px;
  padding: 0.45rem 0.9rem;
  cursor: pointer;
  transition: all 0.25s ease;
}

.exercise-output button:hover {
  background-color: #e7a9d0;
  transform: scale(1.05);
}

/* --- Image & Boxes Layout --- */
.interactive-area {
  display: flex;
  gap: 1.2rem;
  align-items: flex-start;
  margin-top: 1.2rem;
  flex-wrap: wrap;
}

.image-display img {
  width: 260px;
  border-radius: 16px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
}

.feature-boxes {
  flex: 1;
}

.feature-boxes div {
  background-color: #fdf0f9;
  padding: 1rem;
  margin-bottom: 1rem;
  border-radius: 12px;
  border: 1px solid #f6d3ea;
  transition: all 0.3s ease;
}

.feature-boxes div:hover {
  background-color: #fde7f5;
}

/* --- Footer --- */
.site-footer {
  text-align: center;
  padding: 1rem 0;
  background: linear-gradient(90deg, #f9d1e9, #e2c8ff);
  color: #6d4b74;
  font-size: 0.9rem;
  letter-spacing: 0.3px;
  border-top: 3px solid #f4bde3;
  transition: background 0.4s, color 0.4s;
}

/*  Dark Mode — Full Page Active */
.dark-mode {
  background: linear-gradient(180deg, #1b0f22 0%, #2a0f3a 100%);
  color: #f9e6ff;
}

/* Header & Footer */
.dark-mode .site-header,
.dark-mode .site-footer {
  background: linear-gradient(90deg, #4b2b5f, #6b3a8a);
  color: #f9e6ff;
  border-color: #9a6ac5;
}

/* Sidebar & Content */
.dark-mode .sidebar,
.dark-mode .content {
  background-color: #1a0f24;
  color: #f9e6ff;
  box-shadow: 0 0 12px rgba(255, 200, 255, 0.1);
}

/* About & Exercise Cards in Dark Mode */
.dark-mode .about-section,
.dark-mode .exercise-output {
  background-color: #0a080c;
  border-color: #dfd7e5;
  box-shadow: 0 0 10px rgba(138, 86, 181, 0.3);
}

/* Buttons */
.dark-mode button {
  background-color: #08020c;
  color: #fff;
}

.dark-mode button:hover {
  background-color: #a36adf;
}

/* Inputs */
.dark-mode input[type="text"],
.dark-mode input[type="number"] {
  background-color: #0d0a0f;
  border: 1px solid #a36adf;
  color: #f9e6ff;
}

/* Feature Boxes */
.dark-mode .feature-boxes div {
  background-color: #0f0e10;
  border: 1px solid #8a56b5;
}

/* Image Border Style in Dark Mode */
.dark-mode .image-display img {
  box-shadow: 0 0 10px rgba(170, 120, 220, 0.3);
}

/* Container box */
.todo-box {
  max-width: 300px;
  padding: 20px;
  border: 2px solid #333; 
  border-radius: 10px;
  background-color: var(--main-bg-color, #f9f9f9);
  margin: 10px 0;
}

/* Input field */
.todo-input {
  width: 100%;
  padding: 5px;
  margin-bottom: 10px;
  border-radius: 5px;
  border: 1px solid #ccc; 
}

/* Add button */
.todo-btn {
  width: 100%;
  padding: 5px;
  border: none;
  border-radius: 5px;
  background-color: var(--accent-color, #4CAF50); 
  color: white;
  cursor: pointer;
  font-weight: bold;
}

/* Button hover effect */
.todo-btn:hover {
  background-color: var(--accent-hover, #45a049); 
}

/* List items */
.todo-list {
  margin-top: 10px;
  padding-left: 20px;
}

/* Individual item */
.todo-item {
  padding: 5px 0;
  border-bottom: 1px solid #ccc; 
}

/* Container box */
.calc-box {
  max-width: 300px;
  padding: 20px;
  margin: 10px 0;
  border: 2px solid var(--main-border-color, #333); 
  border-radius: 10px;
  background-color: var(--main-bg-color, #f9f9f9);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Input fields */
.calc-input {
  padding: 8px;
  border: 1px solid var(--input-border, #ccc); 
  border-radius: 5px;
  width: 100%;
  font-size: 16px;
}

/* Button */
.calc-btn {
  padding: 8px;
  border: none;
  border-radius: 5px;
  background-color: var(--accent-color, #4CAF50); 
  color: white;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s;
}

.calc-btn:hover {
  background-color: var(--accent-hover, #45a049); 
}

/* Result text */
.calc-res {
  font-weight: bold;
  font-size: 18px;
  color: var(--text-color, #333);
}

/* Calculator box */
.calc-box {
  max-width: 350px;
  padding: 20px;
  margin: 10px 0;
  border: 2px solid var(--main-border-color, #333);
  border-radius: 10px;
  background-color: var(--main-bg-color, #f9f9f9);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Title and info */
.calc-title {
  margin: 0;
  font-size: 20px;
  text-align: center;
  color: var(--text-color, #333);
}
.calc-info {
  margin: 0 0 10px 0;
  font-size: 14px;
  text-align: center;
  color: var(--text-color, #555);
}

/* Inputs */
.calc-input {
  width: 100%;
  padding: 8px;
  border-radius: 5px;
  border: 1px solid var(--input-border, #ccc);
  font-size: 16px;
}

/* Buttons */
.calc-btn {
  width: 100%;
  padding: 8px;
  border: none;
  border-radius: 5px;
  background-color: var(--accent-color, #4CAF50);
  color: white;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s;
}
.calc-btn:hover {
  background-color: var(--accent-hover, #45a049);
}
.reset-btn {
  background-color: var(--reset-color, #f44336);
}
.reset-btn:hover {
  background-color: var(--reset-hover, #d32f2f);
}

/* Result */
.calc-res {
  font-weight: bold;
  font-size: 18px;
}

/* Grade table */
.grade-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
  text-align: center;
}
.grade-table th, .grade-table td {
  border: 1px solid #ccc;
  padding: 5px;
}
.grade-table th {
  background-color: var(--accent-color, #4CAF50);
  color: white;
}

