﻿/* でんこ / denpa_is_crazy — first pass
   Manila folder on a desk, cards layered on top. No build, no framework. */

:root {
  --desk: #faf3f7;
  --kraft: #b08a66;
  --kraft-dark: #8f6b4a;
  --kraft-light: #c49a74;
  --sheet: #fff8fb;
  --ink: #4a3f46;
  --cream: #fff4f8;
  --teal: #8a5270;
  --brand: #e68ab8;
  --brand-deep: #c45a92;
  --brand-soft: #f6d6e6;
  --coral: var(--brand);
  --mint: var(--brand-soft);

  --font-ja: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Noto Sans JP", "Yu Gothic", "Meiryo", sans-serif;
  --font-display: "Fredoka", "Hiragino Maru Gothic ProN", "Arial Rounded MT Bold", var(--font-ja);

  /* SVG noise for a paper feel */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .12 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--grain), var(--desk);
  color: var(--ink);
  font-family: var(--font-ja);
  line-height: 1.8;
  letter-spacing: .02em;
}

a { color: inherit; }

/* ---------- header ---------- */

.site-header {
  display: flex;
  align-items: flex-end;
  gap: 1.25rem;
  flex-wrap: wrap;
  padding: 1.5rem clamp(1rem, 4vw, 2.5rem) 0;
}



.brand {
  display: flex;
  align-items: baseline;
  gap: .6rem;
  text-decoration: none;
}

.brand-ja {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 900;
  line-height: 1;
}

.brand-en {
  font-family: var(--font-display);
  font-size: .9rem;
  opacity: .7;
}

.tagline {
  margin: 0;
  font-size: .8rem;
  line-height: 1.5;
}


/* ---------- folder ---------- */

.desk {
  padding: 3.5rem clamp(.75rem, 4vw, 3rem) 2rem;
}

.folder {
  position: relative;
  max-width: 1180px;
  margin: 0 auto;
}

/* back cover with the big center tab */
.folder-back {
  position: absolute;
  inset: 0;
  background: var(--grain), var(--kraft-dark);
  border-radius: 28px;
  box-shadow:
    inset 0 0 0 1px rgb(60 40 20 / .18),
    0 6px 18px -8px rgb(60 40 20 / .4);
}

.folder-back::before {
  content: "";
  position: absolute;
  top: -2.6rem;
  left: 46%;
  width: 34%;
  height: 3.2rem;
  background: inherit;
  border-radius: 22px 22px 0 0;
}

/* white sheet peeking out between covers */
.folder-sheet {
  position: absolute;
  top: 1.4rem;
  left: 2%;
  right: 2%;
  bottom: 1rem;
  background: var(--sheet);
  border-radius: 4px;
  box-shadow: 0 1px 2px rgb(0 0 0 / .15);
  transform: rotate(-.4deg);
}

/* front cover with the small left tab */

.folder-front {
  position: relative;
  margin-top: 3.2rem;
  padding: clamp(1rem, 3vw, 2rem);
  background: var(--grain), var(--kraft);
  border-radius: 22px;
  box-shadow:
    inset 0 1px 0 rgb(255 245 225 / .25),
    inset 0 0 0 1px rgb(60 40 20 / .15),
    0 -2px 6px rgb(0 0 0 / .12);
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1rem;
}

.folder-front::before {
  content: "";
  position: absolute;
  top: -2rem;
  left: 8%;
  width: 26%;
  height: 2.6rem;
  background: var(--grain), var(--kraft);
  border-radius: 18px 18px 0 0;
}

/* ---------- cards ---------- */

.card {
  position: relative;
  padding: clamp(1.1rem, 2.5vw, 1.8rem);
  background-image: var(--grain);
  box-shadow:
    0 1px 1px rgb(0 0 0 / .12),
    0 8px 18px -6px rgb(0 0 0 / .35);
}

.card p { margin: 0 0 1em; }
.card p:last-child { margin-bottom: 0; }

.card-label {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  opacity: .8;
}

.card-title {
  margin: 0 0 .75rem;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 700;
  line-height: 1;
}

/* About — deep teal, tall, left */
.card-about {
  grid-column: 1 / 6;
  grid-row: 1 / 3;
  background-color: var(--teal);
  color: var(--cream);
  transform: rotate(-1deg);
  overflow: hidden;
  z-index: 1;
}

.card-about .card-label { margin-bottom: .2rem; }




/* quiet stamp in the bottom-right corner, below everything else */
.big-word {
  clear: both;
  margin: 1.25rem -.1rem -.6rem 0 !important;
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  font-weight: 600;
  line-height: 1;
  text-align: right;
  color: var(--brand);
  opacity: .55;
  white-space: nowrap;
  pointer-events: none;
}

/* Work — brand pink, overlaps About */
.card-work {
  grid-column: 5 / 10;
  grid-row: 1 / 2;
  margin-top: 2rem;
  background-color: var(--coral);
  color: var(--ink);
  transform: rotate(.8deg);
  z-index: 2;
}

.work-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
}

.work-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--ink);
}

.work-list a {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  padding: .7rem 0;
  border-bottom: 1px solid rgb(35 34 39 / .45);
  text-decoration: none;
}

.work-name { font-weight: 800; }

.work-meta {
  font-size: .78rem;
  text-align: right;
}

.work-list a:hover .work-name,
.work-list a:focus-visible .work-name {
  text-decoration: underline;
  text-underline-offset: .25em;
}

/* Memo — soft brand note, tilted */
.card-memo {
  grid-column: 10 / 13;
  grid-row: 1 / 2;
  align-self: start;
  margin-top: .5rem;
  background-color: var(--mint);
  font-size: .85rem;
  transform: rotate(3deg);
  z-index: 1;
}

.memo-date {
  font-family: var(--font-display);
  font-size: 1.1rem;
  border-bottom: 1px dashed currentColor;
}

/* Contact — dark ink sheet laid over the bottom right */
.card-contact {
  grid-column: 6 / 13;
  grid-row: 2 / 3;
  margin-top: -1.5rem;
  background-color: var(--ink);
  color: var(--cream);
  transform: rotate(-.5deg);
  z-index: 3;
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
}

.contact-links a {
  display: inline-block;
  padding: .35rem 1rem;
  border: 1px solid var(--cream);
  border-radius: 999px;
  font-size: .85rem;
  text-decoration: none;
}

.contact-links a:hover,
.contact-links a:focus-visible {
  background: var(--brand);
  color: var(--ink);
  border-color: var(--brand);
}

/* ---------- photos ---------- */

/* paper-photo border so the flat render background reads as a print, not a hole */
.polaroid {
  margin: 0;
  padding: .45rem .45rem .75rem;
  background: var(--grain), var(--sheet);
  color: var(--ink);
  box-shadow:
    0 1px 1px rgb(0 0 0 / .15),
    0 10px 20px -8px rgb(0 0 0 / .45);
}

.polaroid img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: #7a7a7a;
  /* soft vignette keeps the flat backdrop from looking like an empty box */
  -webkit-mask-image: radial-gradient(ellipse 120% 100% at 50% 40%, #000 70%, rgb(0 0 0 / .82) 100%);
          mask-image: radial-gradient(ellipse 120% 100% at 50% 40%, #000 70%, rgb(0 0 0 / .82) 100%);
}

.polaroid figcaption {
  padding: .35rem .2rem .45rem;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
}

/* primary avatar, pinned into the About card */
.about-photo {
  float: right;
  width: 44%;
  margin: -.25rem -.25rem .75rem 1rem;
  transform: rotate(3deg);
}

.about-photo img { object-position: 50% 30%; }

/* the other three, scattered across the bottom of the folder */
.photo-strip {
  grid-column: 2 / 13;
  grid-row: 3 / 4;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  margin-top: -1rem;
  padding: 0 1rem .5rem;
  z-index: 4;
}

.strip-photo {
  position: relative;
  flex: 0 1 200px;
  min-width: 0;
}

.strip-photo + .strip-photo { margin-left: -1.75rem; }

.strip-photo-1 { transform: rotate(-5deg) translateY(.6rem); z-index: 2; }
.strip-photo-1 img { object-position: 52% 32%; }

.strip-photo-2 { transform: rotate(2.5deg) translateY(-.4rem); z-index: 1; }
.strip-photo-2 img { object-position: 48% 22%; }


.tape-photo {
  top: -.45rem;
  left: 18%;
  right: auto;
  width: 3.8rem;
  height: 1.15rem;
  background: rgb(230 138 184 / .4);
  transform: rotate(-8deg);
}

.tape {
  position: absolute;
  top: -.6rem;
  right: 1.5rem;
  width: 5.5rem;
  height: 1.6rem;
  background: rgb(230 138 184 / .45);
  transform: rotate(6deg);
}

/* simple paper clip drawn with borders */
.clip {
  position: absolute;
  top: -1.4rem;
  right: 2.2rem;
  width: 1.1rem;
  height: 3rem;
  border: 3px solid #555;
  border-radius: 999px;
}

.clip::after {
  content: "";
  position: absolute;
  inset: .45rem .15rem .2rem;
  border: 2px solid #555;
  border-bottom: 0;
  border-radius: 999px 999px 0 0;
}

/* ---------- footer ---------- */

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1rem clamp(1rem, 4vw, 2.5rem) 2rem;
}

.site-footer nav {
  display: flex;
  gap: clamp(1rem, 6vw, 5rem);
}

.site-footer nav a {
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 2.5vw, 1.8rem);
  text-decoration: none;
}

.site-footer nav a:hover,
.site-footer nav a:focus-visible { text-decoration: underline; }

.credits {
  flex-basis: 100%;
  font-size: .7rem;
  line-height: 1.6;
  opacity: .7;
}

.credits p { margin: 0; }

.about-more { font-size: .85rem; }

.copyright {
  margin: 0;
  font-size: .75rem;
  opacity: .7;
}

/* keep About text clear of the overlapping Work card (desktop grid only) */
@media (min-width: 861px) {
  .card-about { padding-right: clamp(3.5rem, 7vw, 5.5rem); }
}
/* ---------- responsive ---------- */

@media (max-width: 860px) {
.folder-front {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .card-about,
  .card-work,
  .card-memo,
  .card-contact {
    grid-column: 1;
    grid-row: auto;
    margin-top: 0;
  }

  .card-about { transform: rotate(-.6deg); }
  .card-work { transform: rotate(.6deg); }
  .card-memo { transform: rotate(1.5deg); justify-self: end; max-width: 80%; }
  .card-contact { transform: rotate(-.4deg); }

  .about-photo { width: 40%; max-width: 180px; }

  .big-word { font-size: clamp(2rem, 11vw, 2.8rem); }

  .photo-strip {
    grid-column: 1;
    grid-row: auto;
    margin-top: 0;
    padding: 0 .5rem 1rem;
  }

  .strip-photo { flex-basis: 42%; }
  .strip-photo + .strip-photo { margin-left: -6%; }

  .folder-back::before { left: 40%; width: 45%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
