body[data-template="pin"] {
  background: #080807;
  color: #e8dfcf;
}

body[data-template="pin"] .artifact-shell {
  max-width: 780px;
  margin: 0 auto;
  padding: clamp(1rem, 4vw, 2rem);
}

.pin-header {
  margin-bottom: 1.5rem;
}

.pin-header h1 {
  font-size: clamp(2rem, 7vw, 4rem);
  line-height: 0.95;
  margin: 0.35rem 0 0.75rem;
}

.pin-code {
  color: #8f8473;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: -0.25rem 0 0.75rem;
}

.pin-subtitle {
  color: #b8aa92;
  max-width: 42rem;
  font-size: 1rem;
}

.pin-console {
  border: 1px solid rgba(212, 159, 63, 0.35);
  border-radius: 22px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.025);
}

.pin-statusbar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid rgba(212, 159, 63, 0.25);
}

.pin-statusbar div {
  padding: 0.9rem;
  border-right: 1px solid rgba(212, 159, 63, 0.2);
}

.pin-statusbar div:last-child {
  border-right: 0;
}

.pin-statusbar span {
  display: block;
  color: #9c8e78;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.pin-statusbar strong {
  display: block;
  margin-top: 0.25rem;
  color: #f2e9db;
}

.tab-nav {
  display: flex;
  border-bottom: 1px solid rgba(212, 159, 63, 0.25);
}

.tab-button {
  flex: 1;
  border: 0;
  border-right: 1px solid rgba(212, 159, 63, 0.2);
  padding: 0.85rem;
  background: transparent;
  color: #b8aa92;
  cursor: pointer;
  font-weight: 700;
}

.tab-button:last-child {
  border-right: 0;
}

.tab-button.active {
  background: rgba(212, 159, 63, 0.14);
  color: #fff4df;
}

.tab-panel {
  display: none;
  padding: 1.2rem;
}

.tab-panel.active {
  display: block;
}

.guestbook-form {
  display: grid;
  gap: 0.8rem;
}

.guestbook-form input,
.guestbook-form textarea {
  width: 100%;
  box-sizing: border-box;
  background: #050504;
  color: #f4ead8;
  border: 1px solid rgba(212, 159, 63, 0.45);
  border-radius: 12px;
  padding: 0.85rem;
  font: inherit;
}

.guestbook-form textarea {
  min-height: 120px;
  resize: vertical;
}

.guestbook-scroll {
  max-height: 45vh;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.guestbook-entry {
  border-bottom: 1px solid rgba(212, 159, 63, 0.18);
  padding: 0.9rem 0;
}

.guestbook-entry:first-child {
  padding-top: 0;
}

.guestbook-entry strong {
  display: block;
  color: #fff4df;
}

.guestbook-entry p {
  margin: 0.35rem 0;
}

.guestbook-entry span {
  color: #9c8e78;
  font-size: 0.8rem;
}

.object-info div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid rgba(212, 159, 63, 0.18);
  padding: 0.7rem 0;
}

.object-info dt {
  color: #9c8e78;
}

.object-info dd {
  margin: 0;
}

body[data-template="pin"][data-theme="archive"] {
  background: #0b0b0a;
  color: #e7e0d4;
}

body[data-template="pin"][data-theme="field"] {
  background: #0a0d09;
  color: #e4eadc;
}

body[data-template="pin"][data-theme="terminal"] {
  background: #050806;
  color: #d8ffe0;
}

body[data-template="pin"][data-theme="terminal"] .pin-console,
body[data-template="pin"][data-theme="terminal"] .guestbook-form input,
body[data-template="pin"][data-theme="terminal"] .guestbook-form textarea {
  border-color: rgba(120, 255, 165, 0.45);
}

body[data-template="pin"][data-theme="terminal"] .tab-button.active {
  background: rgba(120, 255, 165, 0.12);
  color: #d8ffe0;
}

@media (max-width: 640px) {
  .pin-statusbar {
    grid-template-columns: 1fr;
  }

  .pin-statusbar div {
    border-right: 0;
    border-bottom: 1px solid rgba(212, 159, 63, 0.2);
  }

  .pin-statusbar div:last-child {
    border-bottom: 0;
  }
}