/* Material study: used book cloth, paper edges and local handling marks. */
:root {
  --dry-ink: url("assets/material/ink-wear.c2608980f25a.png");
  --desk: #273039;
  --cover: #245473;
  --cover-dark: #173e58;
  --paper: #f3f0e4;
  --rule: #b8c2bc;
  --cloth: url("assets/material/cloth.b82c2ee4d0ee.png");
  --paper-grain: url("assets/material/paper.07e3ea4cec46.png");
  --guilloche: repeating-radial-gradient(ellipse at 0 0, transparent 0 20px, #07569401 20px 21px), repeating-radial-gradient(ellipse at 100% 0, transparent 0 20px, #07569401 20px 21px);
}
body { background: var(--fibers), radial-gradient(ellipse at 43% 27%, #3c4b53, #273039 78%); }
.passport-board {
  border-radius: 5px 14px 12px 4px;
  background-color: var(--cover);
  background-image: var(--cloth), radial-gradient(ellipse at 85% 12%, #74909a20, transparent 48%), linear-gradient(96deg, #173e58 0, #285a77 7%, #245473 29%, #20506f 76%, #315e77 100%);
  background-size: 110px 110px, auto, auto;
  box-shadow: -2px 1px 1px #0d2634, inset 0 1px 1px #a2b4ae70, inset -1px -1px 2px #c3bda550, 1px 3px 0 #12394f, 3px 5px 0 -1px #b9b9a8, 4px 7px 0 -2px #18384b, 3px 14px 16px -8px #071016b0, 6px 29px 40px -11px #0a10178c;
}
.passport-board::before {
  inset: 0 auto 0 0; width: 31px; border: 0; border-radius: 4px 0 0 4px;
  background: linear-gradient(90deg, #0b283b55, transparent 29%, #a8b7ad28 46%, #0c2c435c 53%, #9bafa318 59%, transparent 88%);
  box-shadow: 1px 0 1px #143e4f33;
}
.passport-board::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit;
  background: url("assets/material/cover-wear.95154e23d6db.png") center/100% 100% no-repeat;
  pointer-events: none; z-index: 1;
}
.cover-face { position: relative; z-index: 2; }
.cover-open { z-index: 3; }
.cover-logo {
  position: relative; background: var(--paper-grain), linear-gradient(165deg, #faf8e9, #eee9d9);
  border-radius: 1px 3px 1px 2px;
  box-shadow: 0 1px 1px #071a2c70, 1px 3px 3px -2px #071a2c90, inset 0 0 0 1px #998b6930;
  clip-path: polygon(.1% 0, 99% .3%, 100% 2%, 99.8% 99%, 1% 100%, 0 97%);
}
.cover-logo::after {
  content: ''; position: absolute; right: 0; top: 0; width: 17px; height: 17px;
  background: linear-gradient(45deg, transparent 46%, #a49f8b30 48%, #fffef2 53%, #e4dfcc 100%);
  clip-path: polygon(0 0,100% 0,100% 100%); pointer-events: none;
}
.cover-kind, .cover-title, .cover-document, .cover-city {
  color: #d9ded2; text-shadow: 0 1px 0 #ffffff0e, 0 -1px 1px #102b3c8f;
  -webkit-mask-image: var(--dry-ink); mask-image: var(--dry-ink);
  -webkit-mask-size: 280px 280px; mask-size: 280px 280px;
}
.cover-rule { background: #c5cfbca6; box-shadow: 0 -1px 1px #112c3d88; }
.cover-corner {
  border-radius: 3px 0 11px 0;
  background: var(--cloth), linear-gradient(135deg, #3b6b84 0%, #577d8d 44%, #153e53 49%, #a8aa94 51%, #e3dfcd 55%, #f3f0e4 100%);
  box-shadow: -2px -1px 3px #091c2b45;
}
.book-cover {
  border-color: transparent; border-radius: 9px 11px 12px 8px;
  background: var(--cloth), linear-gradient(100deg, #254c65, #37647a 9%, #204c67 46%, #264e68 75%, #426c7e);
  background-size: 110px 110px, auto;
  box-shadow: inset 0 1px 1px #b0bba06b, inset 0 -1px 2px #102e43, 0 2px 0 #102f42, 2px 7px 9px -4px #091923ba, 3px 24px 37px -10px #071016a8;
}
.book-cover::before {
  inset: -9px; border: 0; border-radius: 8px;
  background: url("assets/material/cover-wear.95154e23d6db.png") center/100% 100%; opacity: .72;
}
.book-pages {
  background: #c6c1ad; border-radius: 1px 3px 4px 2px;
  box-shadow: 1px 2px 0 #d5d0bb, -1px 3px 0 #a8a994, 1px 4px 0 #e3dfca, 2px 5px 0 #b0b29d, 2px 7px 3px -2px #102b38aa;
}
.leaf {
  background-color: var(--paper);
  background-image: var(--paper-grain), url("assets/material/paper-tone.67f8b5171194.png");
  background-size: 240px 240px, 100% 100%;
}
.leaf:nth-of-type(even) { background-color: #f4f1e6; }
.leaf.is-left { border-radius: 2px 0 0 4px; box-shadow: inset 1px 0 2px #a9956b38, inset -32px 0 23px -21px #655f4a5c; }
.leaf.is-right { border-radius: 0 3px 6px 0; box-shadow: inset -1px 0 2px #a9956b44, inset 32px 0 23px -22px #655f4a5c; }
.leaf::before { border-color: #8b9c995c; opacity: .65; }
.leaf-patina { position: absolute; inset: 0; pointer-events: none; z-index: 0; background-position: center; background-size: 100% 100%; }
.leaf-content, .folio { z-index: 1; }
.leaf[data-leaf-key="consultations"] .leaf-patina::after, .leaf[data-leaf-key="dental-info"] .leaf-patina::after {
  content: ''; position: absolute; width: 85px; height: 105px; right: 12px; bottom: 103px;
  background: url("assets/material/watermark.96d994bbb6f4.png") center/100% 100%; pointer-events: none;
}
.leaf[data-leaf-key="dental-info"] .leaf-patina::after { width: 73px; height: 91px; right: 8px; bottom: 168px; transform: rotate(-19deg); opacity: .75; }
.leaf-patina { overflow: hidden; border-radius: inherit; }
.binding {
  width: 32px; left: calc(50% - 16px);
  background: linear-gradient(90deg, transparent, #776c4f18 22%, #a79e8066 42%, #756e554d 48%, #e9e3cc 51%, #968e7555 54%, #d2cbb58a 62%, transparent 100%);
}
.binding::after {
  width: 4px; left: 14px; top: 0; bottom: 0;
  background: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='720' viewBox='0 0 4 720'%3E%3Cg fill='none' stroke-linecap='round'%3E%3Cpath d='M2 117q-2 9 0 19M2 347q2 10 0 21M2 589q-1 9 0 18' stroke='%235f5946' stroke-width='2.3' opacity='.5'/%3E%3Cpath d='M1.8 117q-1.5 9 .2 19M1.8 347q1.7 10 .2 21M1.8 589q-.8 9 .2 18' stroke='%23c7bfa2' stroke-width='1.2'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 100% 100%;
}
.stamp {
  color: #276390; opacity: .85;
  -webkit-mask-image: var(--dry-ink); mask-image: var(--dry-ink);
  -webkit-mask-size: 100% 100%; mask-size: 100% 100%;
}
.mounted-photo {
  position: relative; border-color: #f7f3e6; outline-color: #b5b3a1;
  box-shadow: 1px 2px 2px #514b3933, 3px 5px 5px -4px #514b3955;
}
.mounted-photo:not(.map)::before, .mounted-photo:not(.map)::after {
  content: ''; position: absolute; z-index: 2; width: 24px; height: 24px; pointer-events: none;
  background: var(--paper-grain), linear-gradient(135deg, #d9d4bf, #f8f4e6 53%, #b6b19f 55%, transparent 59%);
}
.mounted-photo:not(.map)::before { top: -8px; left: -8px; }
.mounted-photo:not(.map)::after { right: -8px; bottom: -8px; transform: rotate(180deg); }
.index-tab {
  border-color: #8d7f5633; background-image: var(--paper-grain), linear-gradient(100deg, #fff7d219, transparent 42%, #806b3b10);
  box-shadow: 1px 2px 3px #101d2850, inset 0 1px 0 #fff7d475;
}
.index-tab::before { border-color: #544c382b; }
.index-tab span { text-shadow: .3px .3px 0 #192c4015; }
.page-corner::before { background: linear-gradient(43deg, #c6c4ad, #f6f2e1 61%, #aaa993); filter: drop-shadow(0 -1px 1px #5b553e35); }
.page-corner.next::before { background: linear-gradient(-43deg, #c6c4ad, #f6f2e1 61%, #aaa993); }
@media (max-width: 1000px) {
  .passport-board { border-radius: 4px 11px 12px 3px; }
  .passport-board::before { width: 24px; }
  .book-cover { border-radius: 5px 7px 8px 5px; box-shadow: inset 0 1px 1px #a3b4a265, 0 2px 1px #112f40, 2px 8px 14px #07101670; }
  .book-cover::before { inset: -5px; border-radius: 5px; }
  .book-pages { box-shadow: 0 2px 0 #ccc8b1, 1px 3px 0 #acb099, 1px 4px 1px #263f46; }
  .leaf.is-left, .leaf.is-right { border-radius: 1px 2px 4px 2px; box-shadow: inset 1px 0 2px #aa9d7938, inset 13px 0 11px -12px #756f554a, inset -1px 0 2px #aa9d7930; }
  .index-tab, .index-tab[aria-current] { border-color: #fff3c857; background-image: var(--paper-grain), linear-gradient(100deg, #ffffff16, transparent 30%, #665e3e10); box-shadow: 1px -2px 4px #07162345, inset 0 1px 0 #fff8de90; }
  .index-tab[aria-current] { box-shadow: 2px -3px 6px #07162365, inset 0 1px 0 #fff8de9c; }
  .index-tab::before { border-top-color: #756a3c33; background: linear-gradient(180deg, #fff9df1a, transparent 2px, #65572c12 9px); }
  .index-tab::after { border-right-color: #7e704b35; height: 10px; }
  .leaf[data-leaf-key="consultations"] .leaf-patina::after { right: 0; bottom: 100px; width: 74px; height: 91px; }
  .leaf[data-leaf-key="dental-info"] .leaf-patina::after { right: 3px; bottom: 167px; width: 67px; height: 83px; }
}
@media print {
  .leaf-patina { display: none; }
  .leaf { background: white; }
}

.passport-back-cover {
  border-radius: 14px 5px 4px 12px;
  background-image: var(--cloth), radial-gradient(ellipse at 18% 75%, #74909a18, transparent 48%), linear-gradient(264deg, #173e58 0, #285a77 7%, #245473 29%, #20506f 76%, #315e77 100%);
  box-shadow: 2px 1px 1px #0d2634, inset 0 1px 1px #a2b4ae70, inset 1px -1px 2px #c3bda550, -1px 3px 0 #12394f, -3px 5px 0 -1px #b9b9a8, -4px 7px 0 -2px #18384b, 3px 14px 16px -8px #071016b0, 6px 29px 40px -11px #0a10178c;
}
.passport-back-cover::before { left: auto; right: 0; transform: scaleX(-1); }
.passport-back-cover::after { transform: scaleX(-1); }
.back-cover-face { position: relative; z-index: 2; }
