html, body, main, header, footer {
  padding: 0px;
  margin: 0px;
}

/* === CSS Variables === */
:root {
  --primary: #FF6B8A;
  --primary-light: #FFB6C1;
  --primary-bg: #FFF0F3;
  --text-dark: #333333;
  --text-gray: #666666;
  --text-light: #999999;
  --white: #ffffff;
  --shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  --radius: 12px;
  --border-color: #f0e0e4;
}

/* === Header === */
header {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  text-align: center;
  padding: 24px 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

#header-title {
  margin-bottom: 12px;
}

#resume-title {
  margin: 0;
  font-size: 28px;
  letter-spacing: 4px;
}

#resume-subtitle {
  font-size: 12px;
  letter-spacing: 2px;
  opacity: 0.85;
}

#main-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 4px;
  padding: 8px 0;
}

.nav-link {
  color: var(--white);
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  transition: background 0.3s;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.25);
}

/* === App Layout === */
#app {
  display: flex;
  gap: 24px;
  max-width: 1100px;
  margin: 24px auto;
  padding: 0 16px;
}

/* === Sidebar === */
#sidebar {
  width: 280px;
  flex-shrink: 0;
  position: sticky;
  top: 140px;
  align-self: flex-start;
  max-height: calc(100vh - 160px);
  overflow-y: auto;
}

#sidebar-card {
  padding: 24px;
  text-align: center;
}

#avatar-container {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

#avatar-placeholder {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: var(--primary-bg);
  border: 3px solid var(--primary-light);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='50' cy='38' r='18' fill='%23FFB6C1'/%3E%3Cellipse cx='50' cy='78' rx='30' ry='22' fill='%23FFB6C1'/%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
}

#sidebar-name {
  margin: 0 0 4px;
  font-size: 22px;
  color: var(--primary);
}

#sidebar-position {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--text-gray);
}

#sidebar-contact {
  margin-bottom: 16px;
}

.contact-item {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px dashed var(--border-color);
  font-size: 13px;
}

.contact-label {
  color: var(--text-gray);
}

.contact-value {
  color: var(--text-dark);
  font-weight: 500;
}

.info-table {
  width: 100%;
  border-collapse: collapse;
}

.info-table td {
  padding: 5px 0;
  font-size: 13px;
  border-bottom: 1px dashed var(--border-color);
}

.info-label {
  color: var(--text-gray);
  width: 40%;
}

.info-value {
  color: var(--text-dark);
  text-align: right;
}

/* === Main Content === */
#main-content {
  flex: 1;
  min-width: 0;
}

.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  border: 1px solid var(--border-color);
}

.section-card {
  margin-bottom: 20px;
}

.section-title {
  margin: 0 0 16px;
  font-size: 18px;
  color: var(--primary);
  padding-bottom: 8px;
  border-bottom: 2px solid var(--primary-light);
  display: flex;
  align-items: center;
}

.section-title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 20px;
  background: var(--primary);
  border-radius: 2px;
  margin-right: 10px;
}

/* === Timeline === */
.timeline-item {
  padding: 12px 0;
  border-left: 3px solid var(--primary-light);
  padding-left: 16px;
  margin-bottom: 12px;
}

.timeline-period {
  font-size: 13px;
  color: var(--text-light);
}

.timeline-school {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-dark);
  margin: 4px 0;
}

.timeline-major {
  font-size: 14px;
  color: var(--text-gray);
}

/* === Education === */
.edu-courses h4,
.edu-honors h4 {
  font-size: 14px;
  color: var(--primary);
  margin: 12px 0 6px;
}

.edu-courses p,
.edu-honors p {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.7;
  margin: 0;
}

/* === Experience List === */
.exp-list {
  padding-left: 20px;
  margin: 0;
}

.exp-list li {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.8;
  padding: 2px 0;
}

/* === Skills === */
.skill-group {
  margin-bottom: 12px;
}

.skill-group:last-child {
  margin-bottom: 0;
}

.skill-group h4 {
  font-size: 14px;
  color: var(--primary);
  margin: 0 0 4px;
}

.skill-group p {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.7;
  margin: 0;
}

/* === Hobbies === */
#hobby-list {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 16px;
}

.hobby-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.hobby-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s;
  background-size: 28px 28px;
  background-repeat: no-repeat;
  background-position: center;
}

.hobby-item:hover .hobby-icon {
  transform: scale(1.1);
}

.hobby-dance {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M24 6c-2.2 0-4 1.8-4 4s1.8 4 4 4 4-1.8 4-4-1.8-4-4-4zm-8 16l6 6v12h4V28l6-6-2-2-4 4-4-4-2 2zm-6 4l-4 4 4 4 4-4-4-4z' fill='%23FF6B8A'/%3E%3C/svg%3E");
}

.hobby-paint {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M6 32l14-14 10 10-14 14zm24-16l6-6 8 8-6 6z' fill='%23FF6B8A'/%3E%3Ccircle cx='40' cy='10' r='4' fill='%23FF6B8A'/%3E%3C/svg%3E");
}

.hobby-sing {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M24 6v24c-2 0-4 2-4 4s2 4 4 4 4-2 4-4V20h8v-4h-8V6h-4z' fill='%23FF6B8A'/%3E%3C/svg%3E");
}

.hobby-swim {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M4 34c4-2 8 2 12 0s8-2 12 0 8 2 12 0M4 28c4-2 8 2 12 0s8-2 12 0 8 2 12 0' stroke='%23FF6B8A' stroke-width='3' fill='none'/%3E%3Ccircle cx='26' cy='14' r='6' fill='%23FF6B8A'/%3E%3C/svg%3E");
}

.hobby-read {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M8 8h12l4 4 4-4h12v28H28l-4 4-4-4H8V8z' fill='none' stroke='%23FF6B8A' stroke-width='2'/%3E%3Cpath d='M12 16h8M12 22h8' stroke='%23FF6B8A' stroke-width='1.5'/%3E%3C/svg%3E");
}

.hobby-item span {
  font-size: 13px;
  color: var(--text-gray);
}

/* === Self Evaluation === */
#eval-list {
  padding-left: 20px;
  margin: 0;
}

#eval-list li {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.8;
  padding: 6px 0;
}

/* === Cover Letter === */
#letter-content p {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 2;
  margin: 0 0 8px;
  text-indent: 2em;
}

#letter-content .letter-greeting,
#letter-content .letter-closing,
#letter-content .letter-sign,
#letter-content .letter-ps {
  text-indent: 0;
}

#letter-content .letter-sign {
  text-align: right;
  margin-top: 16px;
}

#letter-content .letter-ps {
  text-align: right;
  color: var(--primary);
  font-weight: 500;
}

/* === Footer === */
footer {
  text-align: center;
  padding: 20px 16px;
  background: var(--white);
  border-top: 1px solid var(--border-color);
  margin-top: 32px;
}

.page-info {
  font-size: 12px;
  color: var(--text-light);
}

.page-info a {
  color: var(--primary);
  text-decoration: none;
}

.page-info a:hover {
  text-decoration: underline;
}

/* === Responsive === */
@media (max-width: 1023px) {
  #app {
    flex-direction: column;
  }

  #sidebar {
    width: 100%;
    position: static;
    max-height: none;
  }

  #sidebar-card {
    padding: 20px;
  }

  #sidebar-personal {
    display: none;
  }
}

@media (max-width: 767px) {
  #resume-title {
    font-size: 22px;
  }

  .nav-link {
    font-size: 11px;
    padding: 4px 10px;
  }

  #app {
    margin: 12px auto;
    padding: 0 8px;
    gap: 12px;
  }

  .section-card {
    padding: 16px;
    margin-bottom: 12px;
  }

  .section-title {
    font-size: 16px;
  }

  #hobby-list {
    gap: 12px;
  }

  .hobby-icon {
    width: 44px;
    height: 44px;
    background-size: 22px 22px;
  }
}

/* === Print === */
@media print {
  header {
    position: static;
    background: none;
    color: var(--text-dark);
  }

  #main-nav {
    display: none;
  }

  #app {
    flex-direction: column;
    max-width: 100%;
  }

  #sidebar {
    width: 100%;
    position: static;
    max-height: none;
  }

  .card {
    box-shadow: none;
    border: 1px solid #ddd;
    break-inside: avoid;
  }

  footer {
    display: none;
  }
}
