* { box-sizing: border-box; }
  body {
    margin: 0;
    min-height: 100vh;
    font-family: Roboto, Helvetica, Arial, sans-serif;
    background: #14100d;
    color: #f5ede3;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 32px 16px 60px;
  }
  h1 { margin: 0 0 6px; font-size: 28px; letter-spacing: .3px; }
  p.sub { margin: 0 0 24px; color: #cbb89f; font-size: 15px; }
  p.sub kbd {
    background: #2a221c; border: 1px solid #4a3b2c; border-radius: 6px;
    padding: 1px 7px; font-size: 13px;
  }

  .creator {
    background: #1f1813;
    border: 1px solid #3a2d20;
    border-radius: 18px;
    padding: 24px 24px 18px;
    box-shadow: 0 20px 60px rgba(0,0,0,.5);
    width: min(560px, 100%);
  }

  .open-row, .board-row {
    display: grid;
    grid-template-columns: 34px repeat(6, 1fr);
    align-items: center;
  }
  .open-row { margin-bottom: 8px; }
  .corner, .fret-num {
    text-align: center;
    color: #8d7a64;
    font-size: 13px;
    user-select: none;
  }
  .open-cell {
    display: flex;
    justify-content: center;
  }
  .open-btn {
    width: 30px; height: 30px;
    border-radius: 50%;
    border: 2px solid #5a4632;
    background: #14100d;
    color: #8d7a64;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all .15s;
    line-height: 1;
  }
  .open-btn.open {
    border-color: #69c56e;
    color: #69c56e;
    background: rgba(105,197,110,.1);
  }
  .open-btn.muted {
    border-color: #6b6b6b;
    color: #888;
  }
  
.linkTxt {
	color: #e8a83c;
	text-decoration: none;
	font-weight: 400;
}
  
  .string-name {
    text-align: center;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .5px;
    margin-top: 10px;
    color: #e8d5b5;
  }
  .string-name small {
    display: block;
    font-weight: 400;
    color: #8d7a64;
    font-size: 11px;
    margin-top: 2px;
  }

  .board {
    background: linear-gradient(180deg, #4a2f1e 0%, #3a2317 60%, #2e1c12 100%);
    border-radius: 12px;
    padding: 0 6px 12px 0;
    border: 1px solid #5a3d26;
    position: relative;
    touch-action: pan-y;
    -webkit-user-select: none;
    user-select: none;
  }
  /* while a barre is being drawn: no text selection anywhere + visible feedback */
  body.is-barring, body.is-barring * {
    -webkit-user-select: none !important;
    user-select: none !important;
    cursor: ew-resize !important;
  }
  .cell {
    position: relative;
    height: 113px;
    cursor: pointer;
    border-bottom: 5px solid #c9a86a;
  }
  /* vertical strings — centered in the cell so dots sit directly on them */
  .cell::before {
    content: "";
    position: absolute;
    top: 0; bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(220,200,170,.9);
    z-index: 0;
  }
  /* string thickness: low E thick -> high E thin */
  .cell.s0::before { width: 6px; }
  .cell.s1::before { width: 5px; }
  .cell.s2::before { width: 4px; }
  .cell.s3::before { width: 3px; }
  .cell.s4::before { width: 2.5px; }
  .cell.s5::before { width: 2px; background: rgba(240,220,190,.95); }

  /* nut on first row (only when starting at fret 1) */
  .board-row:first-child .cell { border-top: 10px solid #e8dcc8; }
  .board-row:first-child .cell:first-of-type { border-top-left-radius: 4px; }
  .board.no-nut .board-row:first-child .cell { border-top: 5px solid #c9a86a; }
  .board-row:last-child .cell { border-bottom: none; }

  .fret-select-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px 16px;
    margin-bottom: 12px;
    font-size: 14px;
    color: #cbb89f;
  }
  .fret-select-row .select-group {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .fret-select-row label { font-weight: 600; }
  .fret-select-row select {
    background: #14100d;
    color: #f5ede3;
    border: 1px solid #5a4632;
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 14px;
    cursor: pointer;
  }
  .fret-select-row .select-group button.action {
    flex: none;
    padding: 6px 14px;
    font-size: 14px;
  }
  .chord-name-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 14px;
    color: #cbb89f;
  }
  .chord-name-row label { font-weight: 600; white-space: nowrap; }
  .chord-name-row input {
    flex: 1;
    min-width: 0;
    background: #14100d;
    color: #f5ede3;
    border: 1px solid #5a4632;
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 14px;
  }
  .chord-name-row input::placeholder { color: #6f5f4d; }

  /* fret inlay dots — drawn as background so ::before stays free for the string */
  .cell.inlay {
    background-image: radial-gradient(circle, rgba(255,255,255,.22) 0 5px, transparent 6px);
    background-position: center;
    background-repeat: no-repeat;
  }
  .cell.barre-preview {
    background-color: rgba(232,168,60,.30);
    box-shadow: inset 0 2px 0 #e8a83c, inset 0 -2px 0 #e8a83c;
  }
  .cell:hover { background-color: rgba(255,255,255,.08); }
  .cell.inlay:hover {
    background-image: radial-gradient(circle, rgba(255,255,255,.22) 0 5px, transparent 6px);
  }
  .cell:hover::after {
    content: "+";
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,.35);
    font-size: 22px;
    font-weight: 300;
    pointer-events: none;
  }
  .cell.has-dot:hover::after, .cell.has-barre:hover::after { display: none; }

  /* barre bar: continuous bar across strings, built from per-cell segments
     spanning center-to-center so it sits exactly on the strings */
  .barre-seg {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 49px;
    background: radial-gradient(circle at 30% 30%, #4d4d4d, #0f0f0f 70%);
    border-top: 2px solid #f5f5f5;
    border-bottom: 2px solid #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    color: #ffd76a;
    z-index: 2;
    user-select: none;
    pointer-events: none;
    box-shadow: 0 3px 10px rgba(0,0,0,.6);
  }
  .cell.barre-mid .barre-seg { left: -1px; right: -1px; }
  .cell.barre-from .barre-seg {
    left: calc(50% - 10px); right: -1px;
    border-left: 2px solid #f5f5f5;
    border-radius: 25px 0 0 25px;
  }
  .cell.barre-to .barre-seg {
    left: -1px; right: calc(50% - 10px);
    border-right: 2px solid #f5f5f5;
    border-radius: 0 25px 25px 0;
  }
  /* overridden by a finger dot elsewhere: same note, light grey */
  .barre-seg.overridden { color: #bbbbbb; }

  .dot {
    position: absolute;
    left: 50%; top: 50%;
    transform: translate(-50%,-50%);
    width: 49px; height: 49px;
    background: radial-gradient(circle at 30% 30%, #4d4d4d, #0f0f0f 70%);
    border: 2px solid #f5f5f5;
    border-radius: 50%;
    box-shadow: 0 3px 10px rgba(0,0,0,.6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    color: #ffd76a;
    z-index: 2;
    animation: pop .18s ease-out;
    user-select: none;
  }
  @keyframes pop {
    from { transform: translate(-50%,-50%) scale(.4); }
    to { transform: translate(-50%,-50%) scale(1); }
  }

  .controls {
    display: flex;
    gap: 10px;
    margin: 18px 0 14px;
  }
  button.action, a.action {
    flex: 1;
    padding: 12px;
    border-radius: 10px;
    border: 1px solid #5a4632;
    background: #2c231b;
    color: #f5ede3;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all .15s;
    text-align: center;
    text-decoration: none;
    line-height: 1.2;
  }
  button.action:hover, a.action:hover { background: #3a2e22; transform: translateY(-1px); }
  button.action.primary, a.action.primary {
    background: #e8a83c;
    border-color: #e8a83c;
    color: #1a120a;
  }
  button.action.primary:hover, a.action.primary:hover { background: #f2b954; }

  .readout {
    background: #14100d;
    border: 1px solid #3a2d20;
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 14px;
    line-height: 1.6;
	text-align: center;
  }
  .readout b { color: #e8a83c; }
  .readout .notes { color: #957f69; }
  .hint { margin-top: 12px; font-size: 13px; color: #8d7a64; text-align: center; }
  #namesRow { margin-top: 2px; margin-bottom: 0; }


  .header-band {
    align-self: stretch;
    margin: -32px -16px 24px;
    background: #0e0b09;
    border-bottom: 1px solid #3a2d20;
  }
  .site-header {
    width: min(900px, 100%);
    display: flex;
    align-items: center;
    gap: 20px;
    margin: 0 auto;
    background: none;
    border: none;
    border-radius: 0;
    padding: 12px 16px;
    box-shadow: none;
  }
  .site-logo { display: flex; align-items: center; margin-right: auto; }
  .site-logo img {
    display: block;
    height: 95px;
    width: auto;
  }
  .menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid #5a4632;
    background: #2c231b;
    color: #f5ede3;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    transition: all .15s;
    line-height: 1;
  }
  .menu-toggle:hover { background: #3a2e22; transform: translateY(-1px); }
  .top-menu {
    display: flex;
    gap: 35px;
    align-items: center;
    background: none;
    border: none;
    padding: 0;
  }
  .top-menu a {
    white-space: nowrap;
    text-align: center;
    padding: 10px 4px;
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    background: transparent;
    color: #cbb89f;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: .2px;
    transition: color .15s, border-color .15s;
  }
  .top-menu a:hover { background: transparent; color: #f5ede3; transform: none; }
  .top-menu a.active {
    background: transparent;
    border: none;
    border-bottom: 2px solid #e8a83c;
    border-radius: 0;
    color: #f5ede3;
    box-shadow: none;
  }
  main { width: min(900px, 100%); display: flex; flex-direction: column; align-items: center; flex: 1; }
  main > h1, main > p.sub { width: 100%; }
  .site-footer {
    align-self: stretch;
    margin: 24px -16px -60px;
    background: #0e0b09;
    border-top: 1px solid #3a2d20;
    color: #8d7a64;
    font-size: 13px;
    text-align: center;
    padding: 18px 16px;
  }
  /* Frontpage image boxes */
  .front-grid { display: flex; flex-direction: row; flex-wrap: wrap; gap: 16px; width: 100%; }
  .front-box { padding: 16px 16px 18px; flex: 0 1 calc(50% - 8px); min-width: 0; }
  /* Chord sheet cards side by side */
  .sheets-grid { display: flex; flex-direction: row; gap: 16px; width: 100%; align-items: stretch; }
  .sheets-grid .creator { flex: 1; min-width: 0; width: auto; }
  .sheets-grid .sheet-preview { width: 75%; }
  .front-image-link {
    position: relative;
    display: block;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #5a3d26;
    text-decoration: none;
    margin-bottom: 14px;
    background: linear-gradient(180deg, #4a2f1e 0%, #3a2317 60%, #2e1c12 100%);
  }
  .front-image-link img {
    display: block;
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform .2s ease-out;
  }
  .front-image-link:hover img { transform: scale(1.03); }
  .front-box-title {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 16px;
    font-size: 44px;
    font-weight: 800;
    letter-spacing: .3px;
    line-height: 1.15;
    color: #f5ede3;
    background: linear-gradient(180deg, rgba(20,16,13,.15) 0%, rgba(20,16,13,.65) 100%);
    text-shadow: 0 2px 12px rgba(0,0,0,.7);
  }
  /* Chord sheet download cards */
  .sheet-title {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: .3px;
    text-align: center;
    margin: 2px 0 4px;
  }
  .sheet-meta {
    text-align: center;
    color: #cbb89f;
    font-size: 13px;
    margin-bottom: 14px;
  }
  /* 3D angled sheet preview: tilted paper stack with floor shadow */
  .sheet-stage {
    perspective: 1200px;
    padding: 12px 14px 16px;
    margin-bottom: 14px;
  }
  .sheet-preview {
    display: block;
    width: 60%;
    margin: 0 auto;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid #5a3d26;
    background: #fff;
    transform: rotateY(-35deg) rotateX(12deg);
    box-shadow:
      2px 2px 0 #ececec,
      4px 4px 0 #dcdcdc,
      6px 6px 0 #cccccc;
    transition: transform .25s ease-out;
  }
  .creator:hover .sheet-preview {
    transform: rotateY(-5deg) rotateX(1deg) translateY(-4px);
    box-shadow:
      2px 2px 0 #ececec,
      4px 4px 0 #dcdcdc,
      6px 6px 0 #cccccc;
  }
  .sheet-preview img {
    display: block;
    width: 100%;
    height: auto;
  }


  button.action:disabled {
    opacity: .45;
    cursor: default;
    transform: none;
  }
  .readout .barre { color: #e8a83c; }
  @media (max-width: 640px) {
    .cell { height: 97px; }
    .dot { width: 42px; height: 42px; }
    .barre-seg { height: 42px; }
    .cell.barre-from .barre-seg { border-radius: 21px 0 0 21px; left: calc(50% - 8px); }
    .cell.barre-to .barre-seg { border-radius: 0 21px 21px 0; right: calc(50% - 8px); }

    .site-header { flex-wrap: wrap; }
    .menu-toggle { display: inline-flex; }
    .top-menu {
      display: none;
      flex-basis: 100%;
      flex-direction: column;
      align-items: stretch;
      gap: 10px;
    }
    .site-header.open .top-menu { display: flex; }
    .top-menu a { text-align: left; }

    .sheet-stage { padding: 8px 8px 12px; }
    .sheet-preview { transform: rotateY(-10deg) rotateX(2deg); }
    .front-grid { flex-direction: column; }
    .front-box { flex: 1 1 auto; }
    .sheets-grid { flex-direction: column; }
    .sheets-grid .sheet-preview { width: 60%; }
    .front-image-link img { height: 160px; }
    .front-box-title { font-size: 25px; }
	.site-logo img {
		height: 64px;
	}
	.site-footer {
		font-size: 10.5px;
	}
  }
 
  /* Content pages reuse the creator card look */
  .creator p a { color: #e8a83c; }
  .creator p a:hover { color: #f2b954; }
  .about-logo {
    display: block;
    width: min(360px, 80%);
    height: auto;
    margin: 24px auto 4px;
  }
