/* ============================================
   SAI RAM MUTHINENI — PAPER PORTFOLIO
   ============================================ */

:root {
  --desk: #1a1a1e;
  --desk-texture: #1e1e22;
  --paper: #faf8f5;
  --paper-dark: #f5f2ed;
  --paper-shadow: rgba(0,0,0,0.35);
  --ink: #1a1a1a;
  --ink-light: #3a3a3a;
  --ink-faint: #6b6b6b;
  --ink-ghost: #999;
  --accent: #c41e3a;
  --accent-soft: #d45368;
  --live: #16a34a;
  --border: #d4d0c8;
  --border-light: #e8e4dc;

  --font-body: 'Patrick Hand', cursive;
  --font-heading: 'Patrick Hand', cursive;
  --font-mono: 'Patrick Hand', cursive;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: #d8d0c2;
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

::selection {
  background: rgba(196,30,58,0.15);
  color: var(--ink);
}

/* ============================================
   DESK BACKGROUND
   ============================================ */

 .desk-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse at 50% 35%, rgba(255,255,255,.42) 0%, transparent 58%),
    linear-gradient(135deg, #cfc5b5 0%, #e3dacb 48%, #c9bead 100%);
}

.desk-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  opacity: 0.4;
  pointer-events: none;
}

/* ============================================
   PAPER
   ============================================ */

.paper {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 900px;
  background: var(--paper);
  border-radius: 2px;
  padding: 48px 52px 40px;
  box-shadow:
    0 1px 1px rgba(0,0,0,0.08),
    0 2px 2px rgba(0,0,0,0.08),
    0 4px 4px rgba(0,0,0,0.08),
    0 8px 8px rgba(0,0,0,0.08),
    0 16px 16px rgba(0,0,0,0.08),
    0 32px 32px rgba(0,0,0,0.12);
  transform: rotate(-0.3deg);
  transition: transform 0.4s ease;
}

.paper:hover {
  transform: rotate(-0.35deg);
}

.paper::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 2px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.4) 0%, transparent 40%),
    linear-gradient(225deg, rgba(0,0,0,0.02) 0%, transparent 40%);
  pointer-events: none;
}

.paper::after {
  content: '';
  position: absolute;
  top: 0; left: 60px; right: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,0,0,0.06), transparent);
}

/* Paper grain texture */
.paper {
  background-image:
    url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.2' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.025'/%3E%3C/svg%3E"),
    linear-gradient(180deg, var(--paper) 0%, var(--paper-dark) 100%);
  background-size: 200px 200px, 100% 100%;
}

/* ============================================
   PAPER CLIP
   ============================================ */

.paper-clip {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
  opacity: 0.7;
}

/* ============================================
   HEADER
   ============================================ */

.paper-header {
  border-bottom: 1.5px solid var(--ink);
  padding-bottom: 16px;
  margin-bottom: 20px;
}

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

.header-name h1 {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1.1;
}

.header-title {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--ink-faint);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 4px;
}

.header-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--ink-faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: var(--paper-dark);
}

.badge-dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
}

.header-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  font-size: 0.78rem;
  color: var(--ink-faint);
}

.header-contact a {
  color: var(--ink-light);
  text-decoration: none;
  border-bottom: 1px dotted var(--border);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.header-contact a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent-soft);
}

.header-contact .sep {
  color: var(--border);
  font-size: 0.6rem;
}

/* ============================================
   SUMMARY
   ============================================ */

.summary {
  margin-bottom: 20px;
  padding: 14px 16px;
  background: rgba(0,0,0,0.02);
  border-left: 3px solid var(--accent);
  font-size: 0.88rem;
  line-height: 1.65;
  color: var(--ink-light);
}

.summary strong {
  color: var(--ink);
  font-weight: 600;
}

/* ============================================
   COLUMNS
   ============================================ */

.paper-columns {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 32px;
}

.paper-col.left {
  border-right: 1px solid var(--border-light);
  padding-right: 24px;
}

/* ============================================
   SECTIONS
   ============================================ */

.paper-section {
  margin-bottom: 22px;
}

.section-heading {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 10px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}

.heading-count {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  color: var(--ink-ghost);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-left: auto;
}

/* ============================================
   SKILLS
   ============================================ */

.skill-category {
  margin-bottom: 10px;
}

.skill-cat-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--ink-ghost);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 5px;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.skill-tags span {
  padding: 2px 7px;
  background: var(--paper-dark);
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--ink-light);
  font-family: var(--font-body);
  transition: all 0.2s ease;
}

.skill-tags span:hover {
  border-color: var(--ink-ghost);
  color: var(--ink);
}

/* ============================================
   EXPERIENCE
   ============================================ */

.exp-item {
  margin-bottom: 8px;
}

.exp-header {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  align-items: baseline;
  margin-bottom: 4px;
}

.exp-header strong {
  font-size: 0.82rem;
  color: var(--ink);
  font-weight: 600;
}

.exp-org {
  font-size: 0.75rem;
  color: var(--ink-faint);
  font-style: normal;
}

.exp-loc {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--ink-ghost);
}

.exp-list {
  list-style: none;
  padding-left: 12px;
}

.exp-list li {
  font-size: 0.76rem;
  color: var(--ink-faint);
  line-height: 1.55;
  margin-bottom: 2px;
  position: relative;
}

.exp-list li::before {
  content: '·';
  position: absolute;
  left: -10px;
  color: var(--border);
}

/* ============================================
   CERTS
   ============================================ */

.cert-item {
  padding: 6px 0;
}

.cert-name {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink);
  display: block;
  margin-bottom: 2px;
}

.cert-detail {
  font-size: 0.72rem;
  color: var(--ink-faint);
}

/* ============================================
   CONTACT
   ============================================ */

.contact-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.contact-pill {
  padding: 4px 12px;
  background: var(--paper-dark);
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--ink-light);
  text-decoration: none;
  transition: all 0.2s ease;
}

.contact-pill:hover {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

/* ============================================
   PROJECTS
   ============================================ */

.project-item {
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--border-light);
}

.project-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.project-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 3px;
}

.project-header strong {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink);
}

.project-live {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  font-weight: 600;
  color: var(--live);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.project-item > p {
  font-size: 0.76rem;
  color: var(--ink-faint);
  line-height: 1.5;
  margin-bottom: 4px;
}

.project-meta-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px;
}

.project-meta-line span {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--ink-ghost);
}

.project-meta-line a {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px dotted var(--border);
  transition: color 0.2s ease;
}

.project-meta-line a:hover {
  color: var(--accent-soft);
}

/* ============================================
   OPEN SOURCE
   ============================================ */

.contrib-item {
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--border-light);
}

.contrib-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.contrib-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.contrib-header strong {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink);
}

.contrib-org {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--ink-ghost);
}

.contrib-item > p {
  font-size: 0.74rem;
  color: var(--ink-faint);
  line-height: 1.5;
}

/* ============================================
   FOOTER
   ============================================ */

.paper-footer {
  margin-top: 24px;
  padding-top: 14px;
  border-top: 1.5px solid var(--ink);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.stamp {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--accent);
  border: 2px solid var(--accent);
  padding: 3px 8px;
  border-radius: 2px;
  transform: rotate(-3deg);
  opacity: 0.7;
  letter-spacing: 0.1em;
}

.footer-text {
  font-size: 0.7rem;
  color: var(--ink-ghost);
  font-style: normal;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
  body {
    padding: 20px 12px;
    align-items: flex-start;
  }

  .paper {
    padding: 28px 22px 24px;
    transform: rotate(0deg);
  }

  .paper:hover {
    transform: rotate(0deg);
  }

  .paper-columns {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .paper-col.left {
    border-right: none;
    padding-right: 0;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 16px;
    margin-bottom: 16px;
  }

  .header-top {
    flex-direction: column;
    gap: 8px;
  }

  .header-name h1 {
    font-size: 1.5rem;
  }

  .paper-footer {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}

@media (max-width: 420px) {
  .paper {
    padding: 22px 16px 20px;
  }

  .header-contact {
    font-size: 0.7rem;
  }

  .summary {
    font-size: 0.82rem;
  }
}



/* =========================================================
   UPRIGHT PEN + REAL NOTEBOOK PAPER
   ========================================================= */

:root {
  --paper: #fffef7;
  --paper-dark: #fffef7;
  --ink: #25282b;
  --ink-light: #35393c;
  --ink-faint: #555b60;
  --ink-ghost: #777d82;
  --accent: #c94b55;
  --border: rgba(65, 112, 155, .25);
  --border-light: rgba(65, 112, 155, .17);
  --font-body: 'Patrick Hand', cursive;
  --font-heading: 'Patrick Hand', cursive;
  --font-mono: 'Patrick Hand', cursive;
}

/* Absolutely no italic text anywhere. */
html, body, body * {
  font-family: 'Patrick Hand', cursive !important;
  font-style: normal !important;
  font-synthesis: none !important;
}

strong, b {
  font-weight: 700 !important;
}

/* Notebook page: cream paper + blue ruled lines + red margin. */
.paper {
  position: relative;
  overflow: hidden;
  max-width: 920px;
  padding: 54px 58px 46px 78px;
  background-color: #fffef7;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180' viewBox='0 0 180 180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.035'/%3E%3C/svg%3E"),
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent 30px,
      rgba(66, 128, 183, .18) 31px,
      transparent 32px
    );
  box-shadow:
    0 2px 4px rgba(0,0,0,.12),
    0 18px 42px rgba(0,0,0,.34);
  border-radius: 1px;
}

/* Red vertical notebook margin. */
.paper::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 48px;
  width: 1.5px;
  background: rgba(201, 75, 85, .48);
  pointer-events: none;
}

/* Disable old decorative paper overlay. */
.paper::before {
  display: none;
}

/* Keep all content above the paper texture. */
.paper > * {
  position: relative;
  z-index: 1;
}

/* Handwritten header. */
.paper-header {
  border-bottom: 2px solid rgba(40, 45, 48, .65);
}

.header-name h1 {
  font-size: 2.15rem;
  font-weight: 700;
  letter-spacing: .01em;
}

.header-title,
.header-contact,
.header-badge {
  font-weight: 400;
}

.header-title {
  font-size: .82rem;
  letter-spacing: .04em;
}

.header-badge {
  background: rgba(255,255,255,.25);
  transform: none;
}

/* No boxed UI/card effect for the summary. */
.summary {
  background: transparent;
  padding: 3px 0 5px 14px;
  border-left: 2px solid rgba(201,75,85,.72);
  font-size: 1rem;
  line-height: 1.55;
}

/* Notebook-style section headings. */
.section-heading {
  font-size: 1.08rem;
  font-weight: 700;
  border-bottom: 1px solid rgba(55,85,110,.35);
  padding-bottom: 2px;
}

.heading-count,
.skill-cat-label,
.project-live,
.project-meta-line span,
.project-meta-line a,
.contrib-org,
.cert-name,
.stamp {
  font-family: 'Patrick Hand', cursive !important;
  font-style: normal !important;
}

/* Handwritten skill list instead of digital-looking pills. */
.skill-tags {
  display: block;
  line-height: 1.8;
}

.skill-tags span {
  display: inline;
  padding: 0;
  margin: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: .86rem;
  font-weight: 400;
}

.skill-tags span:not(:last-child)::after {
  content: "  ·  ";
  color: rgba(70,80,85,.45);
}

/* Let text sit naturally on the notebook rules. */
.project-item,
.contrib-item,
.exp-item,
.cert-item {
  background: transparent;
}

.project-header strong,
.exp-header strong,
.contrib-header strong {
  font-weight: 700;
}

.project-item > p,
.exp-list li,
.cert-detail,
.contrib-item > p {
  font-size: .9rem;
  line-height: 1.48;
  font-weight: 400;
}

.project-meta-line span,
.project-meta-line a {
  font-size: .72rem;
  font-weight: 400;
}

/* Less "website UI", more handwritten notes. */
.contact-pill {
  background: transparent;
  border: 1px solid rgba(55,75,90,.28);
  border-radius: 1px;
  font-size: .82rem;
  padding: 3px 10px;
}

.stamp {
  transform: rotate(-2deg);
  font-size: .75rem;
}

.footer-text {
  font-style: normal !important;
  font-size: .78rem;
}

/* Notebook margin must remain visible on mobile. */
@media (max-width: 768px) {
  .paper {
    padding: 30px 22px 28px 58px;
  }

  .paper::after {
    left: 34px;
  }
}

@media (max-width: 420px) {
  .paper {
    padding: 24px 16px 22px 46px;
  }

  .paper::after {
    left: 27px;
  }
}


/* =========================================================
   WARM DESK / PHYSICAL NOTEBOOK PRESENTATION
   ========================================================= */

.desk-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220' viewBox='0 0 220 220'%3E%3Cfilter id='grain'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='220' height='220' filter='url(%23grain)' opacity='.055'/%3E%3C/svg%3E");
  opacity: .65;
  pointer-events: none;
}

/* A second sheet underneath makes this feel like a real notebook,
   rather than a webpage floating on a black background. */
.paper::after {
  content: "";
  position: absolute;
  top: 5px;
  bottom: -5px;
  left: 7px;
  right: -7px;
  width: auto;
  background: #f5f0e4;
  border: 1px solid rgba(80,70,55,.10);
  box-shadow: 0 7px 18px rgba(55,45,35,.12);
  z-index: -1;
  transform: rotate(0.45deg);
}

/* Notebook itself gets a softer, more physical shadow. */
.paper {
  width: min(94vw, 1180px);
  max-width: 1180px;
  box-shadow:
    0 1px 2px rgba(50,40,30,.10),
    0 5px 12px rgba(50,40,30,.12),
    0 18px 35px rgba(50,40,30,.18);
}

/* Give the page a little more breathing room without making it feel empty. */
@media (min-width: 1000px) {
  .paper {
    padding-left: 88px;
    padding-right: 72px;
  }

  .paper::after {
    left: 48px;
  }

  .paper-columns {
    grid-template-columns: .95fr 1.55fr;
    gap: 38px;
  }
}

/* Slightly larger writing on the wider sheet. */
@media (min-width: 1000px) {
  .header-name h1 {
    font-size: 2.35rem;
  }

  .header-contact {
    font-size: .9rem;
  }

  .summary {
    font-size: 1.03rem;
  }

  .project-item > p,
  .exp-list li,
  .cert-detail,
  .contrib-item > p {
    font-size: .94rem;
  }
}

/* Keep mobile as a single sheet. */
@media (max-width: 768px) {
  .paper {
    width: 96vw;
  }
}
