* {
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
}

body {
  background: #f2f4f7;
  padding: 40px;
}

.container {
  max-width: 1100px;
  margin: auto;
  background: #fff;
  padding: 30px;
}

/* HEADER */
.header {
  display: flex;
  gap: 20px;
  border-bottom: 2px solid #eee;
  padding-bottom: 20px;
}

.avatar {
  width: 140px;
  height: 160px;
  border-radius: 8px;
  object-fit: cover;
}

.title {
  font-weight: 600;
  color: #555;
}

.summary {
  margin-top: 8px;
  font-size: 14px;
  color: #444;
}

/* GRID */
.grid {
  display: grid;
  grid-template-columns: 65% 30%;
  gap: 50px;
  margin-top: 30px;
}

section {
  margin-bottom: 30px;
}

h2 {
  font-size: 16px;
  color: #0f2a44;
  border-bottom: 1px solid #ddd;
  padding-bottom: 6px;
}

.item h3 {
  margin-bottom: 3px;
}

.item span {
  font-size: 13px;
  color: #666;
}

.item ul {
  padding-left: 18px;
  margin-top: 8px;
}

.item li {
  margin-bottom: 6px;
  font-size: 14px;
}

/* TAGS */
.tags span {
  display: inline-block;
  background: #0f2a44;
  color: #fff;
  padding: 6px 10px;
  margin: 5px 5px 0 0;
  border-radius: 20px;
  font-size: 12px;
}
.company {
  margin-bottom: 30px;
}

.role {
  font-size: 13px;
  color: #666;
  display: block;
  margin-bottom: 12px;
}

.project {
  margin-left: 30px;
  margin-bottom: 18px;
}
.comanpy_header{
  margin: 0%;
}

.project h4 {
  margin-bottom: 4px;
  color: #0f2a44;
}

.project a {
  font-size: 13px;
  color: #1a73e8;
  text-decoration: none;
}

.project ul {
  padding-left: 18px;
  margin-top: 6px;
}

.project li {
  margin-bottom: 6px;
  font-size: 14px;
}

.company h3 {
  margin-bottom: 2px;   /* reduce space below company name */
}

.company .role {
  margin-top: 0;        /* remove top gap */
  margin-bottom: 10px; /* keep a little space before projects */
  display: block;
}
/* ======================
   PRINT / PDF FIX
====================== */
@media print {

  @page {
    size: A4;
    margin: 15mm;
  }

  body {
    margin: 0;
    padding: 0;
    background: white;
  }

  .container {
    box-shadow: none;
    padding: 0;
  }

  .grid {
    display: grid;
    grid-template-columns: 65% 35%;
    gap: 20px;
    align-items: start;
  }

  /* Keep logical blocks together */
  .company,
  .project {
    page-break-inside: avoid;
  }

  /* Allow natural section breaks */
  section {
    page-break-inside: auto;
  }

}
