Chapter Text
MENU
HOW TO USE ↑
1. Go to My Dashboard → Skins → My Work Skins → Create Work Skin
2. Paste the CSS for the components you want to use
3. Apply the skin to your work under Edit Work → Post/Edit → Select work skin
4. In your chapter text (HTML mode), paste your HTML code.
If the code is complex (the tab view components especially), I strongly recommend editing it on CodePen rather than directly in AO3's own editor. Here's why: as soon as you post, save a draft or preview it, AO3 strips out inserted comments and breaks the indentation that makes the code easier to read, which makes it far more likely you'll accidentally delete or mix up tags.
— You don't need an account to edit on CodePen. Just close the sign-in prompt if it pops up, unless you'd like to save your code directly there (keep in mind it'll be public unless you have a paid account).
— It works as a live preview, refreshing automatically as you type. For it to be accurate, paste your HTML into the HTML box and the entire CSS into the CSS box. You'll also need to wrap your HTML in a <div id="workskin">, since that's the id AO3 assigns to the work skin container, and the one all this tutorial's CSS is scoped to. Without it, the preview won't work.
For instance:
<div id="workskin">
Your component's HTML here
</div>— Add your text and tweak the code until you're happy with the result, then save your final version into a plain .txt file so you can come back to it later.
— Don't forget to remove the <div id="workskin"> wrapper (both the opening tag and its matching closing </div> at the end) once you paste the HTML into your actual work, as it was only needed for the preview to render correctly on CodePen.
COMPONENTS ↑
1. PARCHMENT ↑
a) Background ↑
A simple, textured parchment background. Can be used alone or with .frame
Standalone demo
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Parchment with frame demo
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
HTML / CSS
HTML → standalone:
<div class="parchment">
<p>Your text here.</p>
</div>HTML → with frame:
<div class="frame">
<div class="parchment">
<p>Your text here.</p>
</div>
</div>Show CSS
CSS parchment:
#workskin .parchment {
max-width: 40em;
margin: auto;
color: black;
font-family: 'Lucida Grande', 'Lucida Sans Unicode', sans-serif;
background: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
padding: 1em 1.3em;
position: relative;
box-sizing: border-box;
}CSS frame:
#workskin .frame {
max-width: 40em;
margin: auto;
padding: 5px;
background: white;
border: 2px solid #F0E7D9;
box-sizing: border-box;
}
b) Scroll ↑
A decorative parchment scroll with a fixed size and scrollable content area.
→ Mobile compatibility: Note that the layout does not adapt to smaller screens; the scroll will overflow on mobile, though the content remains readable.
Demo
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at.
HTML / CSS
<div class="parchment-scroll">
<div class="parchment-scroll-content">
<p>Your text here.</p>
</div>
</div>Show CSS
#workskin .parchment-scroll {
display: flex;
flex-direction: column;
position: relative;
box-sizing: border-box;
width: 600px;
height: 435px;
overflow: hidden;
margin: 10px auto;
padding: 7em 5.3em;
background: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-scroll.png");
background-size: 100%;
background-repeat: no-repeat;
}
#workskin .parchment-scroll-content {
scrollbar-color: #7d5b44 transparent;
max-height: 200px;
padding-inline: 2em;
overflow: auto;
margin: auto;
}
#workskin .parchment-scroll-content p {
color: black;
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
font-size: 18px;
line-height: 1.4;
font-style: italic;
}
c) Single document ↑
An aged parchment document with a wax seal.
Full CSS (includes all the following demos — HTML follows each demo)
Show CSS
/* ============================================================
FOLIO — SINGLE DOCUMENT
============================================================ */
#workskin .folio {
max-width: 38em;
margin: auto;
padding: 4em 2.5em;
box-sizing: border-box;
position: relative;
color: black;
font-family: "Monotype Corsiva", "Apple Chancery", "Palatino Linotype", "Georgia", cursive;
font-style: italic;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
background-size: 100%;
box-shadow: 0 0 10px #bcbcbc;
}
#workskin .folio p {
margin: 15px auto;
}
#workskin .folio-seal {
width: 130px;
height: 87px;
position: absolute;
top: 5px;
right: -20px;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-seal.png");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
filter: drop-shadow(0px 3px 5px rgba(0, 0, 0, 1)) brightness(1.3) contrast(0.9);
}
#workskin .folio > p.folio-title:first-of-type,
#workskin .folio .folio-content {
margin-top: 30px;
}
#workskin .folio-title {
text-align: center;
font-size: 1.5em;
line-height: 1;
border-bottom: 1px solid #4a3e3d;
padding-bottom: 10px;
}
#workskin .folio-content p {
font-size: 18px;
line-height: 1.4em;
}
#workskin .folio-content > p:first-of-type,
#workskin .folio-content > p.folio-img-left:first-of-type + p,
#workskin .folio-content > p.folio-img-right:first-of-type + p {
margin-top: 0;
}
#workskin .folio-content p:last-of-type {
margin-bottom: 0;
}
#workskin .folio-footer {
border-top: 1px solid #4a3e3d;
padding-top: 10px;
font-size: 14px;
text-align: right;
margin-top: 1em;
}
#workskin .folio .accent {
color: #760000;
}
#workskin .folio-content hr {
border: 0;
height: 1px;
background: #2e2416;
width: 45%;
margin: 40px auto;
position: relative;
overflow: visible;
opacity: 0.85;
}
#workskin .folio-content hr::after,
#workskin .folio-content hr::before {
display: inline-block;
position: absolute;
top: -13px;
color: #2e2416;
font-family: "Georgia", serif;
font-size: 18px;
}
#workskin .folio-content hr::after {
content: "❧";
left: -10px;
}
#workskin .folio-content hr::before {
content: "❧";
transform: scaleX(-1);
right: -10px;
}
/* ============================================================
FOLIO — IMAGES
No need to add #workskin .img-float-clear again if already included via another component's image css
============================================================ */
#workskin .folio-content > p:has(img) {
margin: 0;
}
#workskin .folio-content > p.folio-img-left img {
margin-right: 10px;
float: left;
}
#workskin .folio-content > p.folio-img-right img {
margin-left: 10px;
float: right;
}
#workskin .folio-content .img-float-clear + p,
#workskin .folio-content .img-float-clear + p.folio-img-left + p,
#workskin .folio-content .img-float-clear + p.folio-img-right + p {
margin-top: 0;
}
#workskin .img-float-clear {
clear: both;
}Basic document
→ The page expands to fit however much content you add (no scrollbar).
On the Treaty of Westphalia
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
HTML
<div class="folio">
<div class="folio-seal"></div>
<p class="folio-title">Title of the Document</p>
<div class="folio-content">
<p>First paragraph here.</p>
<hr>
<p>Another paragraph here.</p>
</div>
<p class="folio-footer">Footer note here</p>
</div>Document with image
→ Add an image to your document:
- Find the
<p class="folio-img-left"><img width="40%" src="img-url-here"></p>tag, swap in your own URL and adjust the width to your liking. - A mirrored
folio-img-rightclass is also available if you'd rather float the image to the right. - To use a centered image:
<p align="center"><img width="80%" src="img-url-here"></p>. Adjust the width however you like.
Demo
The Treaty of Westphalia

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
HTML
<div class="folio">
<div class="folio-seal"></div>
<p class="folio-title">Title of the Document</p>
<div class="folio-content">
<p class="folio-img-left">
<img width="40%" src="img-url-here">
</p>
<p>First paragraph here.</p>
<div class="img-float-clear"></div>
<p>Another paragraph here.</p>
</div>
<p class="folio-footer">Footer note here</p>
</div>
d) Stack (tab view) ↑
A decorative cover panel and a sidebar of hoverable tabs that reveal your content.
The full code follows the demos (covers both standard and bigger variants).
Standard demo
The Sealed Dossiers
Official Decrees and Classified Records of the Realm
Bigger demo
The Sealed Dossiers
Official Decrees and Classified Records of the Realm
Full code
→ Mobile Compatibility: Note that the layout does not adapt perfectly to smaller screens. The content will overflow on mobile. However, the standard version remains significantly more readable on mobile screens than the .bigger modifier version.
→ Modifier: To switch to larger dimensions, add the class bigger alongside the main class (example: <div class="doc-folio bigger">).
→ How it works: To add a tab, copy the whole tab block (from <!-- TAB START --> to <!-- TAB END -->) and paste it right after the previous one. Since this can be a bit tricky at first, the available classes, adding images, customizing things, and how the code works more broadly are explained in detail at the end of this work.
HTML
<div class="doc-folio">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Subtitle</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START -->
<div class="tab">
<!-- TAB BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Label here.</p>
</div>
</div>
<!-- TAB BUTTON END -->
<!-- TAB CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">
<span class="accent">Tab 1:</span>
Tab title here.
</p>
<p class="tab-section">Section title here.</p>
<p class="img-left">
<img width="40%" src="img-url-here">
</p>
<p>Paragraph here.</p>
<div class="img-float-clear"></div>
<hr>
<p class="tab-section">Another section title here.</p>
<p>Another paragraph here.</p>
</div>
</div>
<!-- TAB CONTENT END -->
</div>
<!-- TAB END -->
</div>
</div>Show CSS
/* ------------------------------------------------------------
SCROLLBAR
------------------------------------------------------------ */
#workskin .doc-folio * {
scrollbar-color: #4b3a2e transparent;
}
/* ------------------------------------------------------------
CONTAINER
Outer wrapper, cover and panels dimensions.
------------------------------------------------------------ */
#workskin .doc-folio {
width: 565px;
margin: auto;
position: relative;
overflow: hidden;
}
#workskin .doc-folio .doc-cover,
#workskin .doc-folio .tab-panel {
width: 375px;
}
#workskin .doc-folio,
#workskin .doc-folio .doc-cover,
#workskin .doc-folio .tab-panel {
height: 444px;
background-color: rgb(195 179 153);
box-sizing: border-box;
}
/* Padding & transparent border */
#workskin .doc-folio .doc-cover {
padding-inline: 19px;
}
#workskin .doc-folio .tab-panel {
border-inline: 19px solid transparent;
}
/* ------------------------------------------------------------
COVER
Decorative left panel with background image.
------------------------------------------------------------ */
#workskin .doc-folio .doc-cover {
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 0;
top: 0;
opacity: 0.9;
z-index: 1;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-cover-folio.jpg");
background-size: contain;
background-repeat: no-repeat;
}
/* ------------------------------------------------------------
COVER — DECORATIVE IMAGE
Icon or illustration displayed on the cover panel.
------------------------------------------------------------ */
#workskin .doc-folio .doc-img {
width: 170px;
height: 95px;
margin-block: 14%;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-seal.png");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
filter: drop-shadow(0px 3px 5px rgba(0, 0, 0, 1)) brightness(1.3) contrast(0.9);
}
/* ------------------------------------------------------------
COVER — HEADLINE
Title and subtitle block displayed on the cover image.
------------------------------------------------------------ */
/* Headline */
#workskin .doc-folio .doc-headline {
width: 100%;
padding-inline: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
box-sizing: border-box;
}
#workskin .doc-folio .doc-headline p {
margin: 0;
font-family: "Monotype Corsiva", "Apple Chancery", "Palatino Linotype", "Georgia", serif;
font-style: italic;
color: black;
text-align: center;
}
/* Title */
#workskin .doc-folio .doc-headline p.doc-title {
padding-bottom: 15px;
padding-inline: 10px;
font-size: 27px;
line-height: 1;
}
/* Subtitle */
#workskin .doc-folio .doc-headline p.doc-subtitle {
padding-top: 15px;
padding-inline: 15px;
font-size: 20px;
line-height: 1;
}
/* ------------------------------------------------------------
SIDEBAR
Right column holding all tab buttons.
Acts as positioning context for all panels.
overflow: hidden clips panels at rest;
:has(.tab:hover) reveals them on hover.
------------------------------------------------------------ */
#workskin .doc-folio .sidebar {
position: absolute;
right: 0;
top: 0;
width: 190px;
height: 100%;
display: flex;
flex-direction: column;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
z-index: 10;
overflow: hidden;
}
#workskin .doc-folio .sidebar:has(.tab:hover) {
overflow: visible;
}
/* ------------------------------------------------------------
TAB
Individual tab item.
------------------------------------------------------------ */
#workskin .doc-folio .tab {
flex: 1;
overflow: hidden;
z-index: 10;
}
#workskin .doc-folio .tab:hover {
overflow: visible;
z-index: 20;
}
/* ------------------------------------------------------------
TAB — BUTTON
Visible area. Reveals the panel on hover.
------------------------------------------------------------ */
#workskin .doc-folio .tab-btn {
display: block;
width: 100%;
height: 100%;
border: ridge rgba(220, 210, 190, 0.8);
background-position: center center;
cursor: pointer;
transition: filter 300ms ease-in-out, opacity 300ms ease-in-out;
box-sizing: border-box;
position: relative;
z-index: 5;
opacity: 0.7;
filter: saturate(80%) sepia(10%);
}
#workskin .doc-folio .tab:hover .tab-btn {
opacity: 0.85;
filter: saturate(40%) sepia(0%);
}
/* ------------------------------------------------------------
TAB BUTTON IMAGES
Default image shared by all tabs. Override per tab using
:nth-child(N) to assign a different image to each category.
Example:
#workskin .doc-folio .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
------------------------------------------------------------ */
#workskin .doc-folio .tab-btn {
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/scrolls.jpg");
background-position: right bottom;
background-size: 200%;
}
/* Per-tab overrides (uncomment and fill in URLs):
#workskin .doc-folio .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folio .tab:nth-child(2) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folio .tab:nth-child(3) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folio .tab:nth-child(4) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folio .tab:nth-child(5) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* ------------------------------------------------------------
TAB — LABEL
Text overlay at the bottom of each tab button.
------------------------------------------------------------ */
#workskin .doc-folio .tab-label {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 6;
box-sizing: border-box;
background-color: rgba(247, 242, 234, 0.88);
border-top: 1px solid rgba(170, 150, 120, 0.35);
box-shadow: 0 0 10px #141414;
border-radius: 25%;
}
/* Label text */
#workskin .doc-folio .tab-label p {
margin-block: 7px;
font-family: "Georgia", "Apple Chancery", "Palatino Linotype", serif;
font-size: 12px;
font-style: italic;
color: black;
font-weight: bold;
text-align: center;
line-height: 1.3;
letter-spacing: 0.02em;
}
#workskin .doc-folio .tab-label .red {
color: #b30000;
}
/* ------------------------------------------------------------
TAB — PANEL
Scrollable content panel revealed on tab hover.
Positioned against .sidebar (its stacking context).
top: 0 keeps it flush with the container top regardless
of which tab is hovered.
------------------------------------------------------------ */
#workskin .doc-folio .tab-panel {
position: absolute;
top: 0;
right: 100%;
z-index: 19;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
background-size: 100%;
background-repeat: repeat;
background-clip: content-box;
overflow: auto;
display: none;
}
#workskin .doc-folio .tab:hover .tab-panel {
display: block;
}
/* ------------------------------------------------------------
TAB — PANEL CONTENT
Inner content area.
------------------------------------------------------------ */
#workskin .doc-folio .tab-content {
width: 100%;
padding: 12px 14px;
box-sizing: border-box;
position: relative;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
background-size: 105%;
background-repeat: repeat;
background-attachment: scroll;
}
#workskin .doc-folio .tab-content p {
font-family: "Monotype Corsiva", "Apple Chancery", "Palatino Linotype", "Georgia", cursive;
color: black;
font-style: italic;
font-size: 18px;
line-height: 22px;
}
#workskin .doc-folio .tab-content p.tab-title {
text-align: center;
font-size: 22px;
padding-bottom: 10px;
border-bottom: 1px solid #4a3e3d;
}
#workskin .doc-folio .tab-content p.tab-section {
font-size: 20px;
}
/* Images */
#workskin .doc-folio .tab-content > p.img-left img {
margin-right: 10px;
float: left;
}
#workskin .doc-folio .tab-content > p.img-right img {
margin-left: 10px;
float: right;
}
#workskin .doc-folio .tab-content .img-float-clear + p,
#workskin .doc-folio .tab-content .img-float-clear + p.img-left + p,
#workskin .doc-folio .tab-content .img-float-clear + p.img-right + p {
margin-top: 0;
}
#workskin .doc-folio .tab-content .img-float-clear {
clear: both;
}
/* Accent colors */
#workskin .doc-folio .accent {
color: #760000; /* red */
}
/* <hr> separator */
#workskin .doc-folio .doc-headline .doc-title-separator,
#workskin .doc-folio .tab-content hr {
border: 0;
height: 1px;
background: #2e2416;
width: 45%;
position: relative;
overflow: visible;
opacity: 0.85;
}
#workskin .doc-folio .doc-headline .doc-title-separator {
margin: 20px auto;
}
#workskin .doc-folio .tab-content hr {
margin: 40px auto;
}
#workskin .doc-folio .doc-headline .doc-title-separator::after,
#workskin .doc-folio .doc-headline .doc-title-separator::before,
#workskin .doc-folio .tab-content hr::after,
#workskin .doc-folio .tab-content hr::before {
display: inline-block;
position: absolute;
top: -13px;
color: #2e2416;
font-family: "Georgia", serif;
font-size: 18px;
}
#workskin .doc-folio .doc-headline .doc-title-separator::after,
#workskin .doc-folio .tab-content hr::after {
content: "❧";
left: -10px;
}
#workskin .doc-folio .doc-headline .doc-title-separator::before,
#workskin .doc-folio .tab-content hr::before {
content: "❧";
transform: scaleX(-1);
right: -10px;
}
/* ------------------------------------------------------------
BIGGER MODIFIER
Add .bigger to switch to larger dimensions.
All overrides for .bigger are grouped here.
Example: <div class="doc-folio bigger">
------------------------------------------------------------ */
/* Container — Outer wrapper, cover and panels dimensions. */
#workskin .bigger.doc-folio {
width: 765px;
}
#workskin .bigger.doc-folio,
#workskin .bigger.doc-folio .doc-cover,
#workskin .bigger.doc-folio .tab-panel {
height: 682px;
}
#workskin .bigger.doc-folio .doc-cover,
#workskin .bigger.doc-folio .tab-panel {
width: 575px;
}
#workskin .bigger.doc-folio .doc-cover {
padding-inline: 29px;
}
#workskin .bigger.doc-folio .tab-panel {
border-inline: 29px solid transparent;
}
/* Cover image and margin */
#workskin .bigger.doc-folio .doc-img {
width: 200px;
height: 125px;
margin-block: 16%;
}
/* Title */
#workskin .bigger.doc-folio .doc-headline p.doc-title {
font-size: 35px;
}
/* Subtitle */
#workskin .bigger.doc-folio .doc-headline p.doc-subtitle {
font-size: 24px;
}
/* Tab labels */
#workskin .bigger.doc-folio .tab-label p {
font-size: 13px;
}
/* Tab button images — add per-tab overrides here, one entry per tab:
.tab:nth-child(1) for the first button, .tab:nth-child(2) for the second button, and so on.
Example:
#workskin .bigger.doc-folio .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* Tab content — Font size */
#workskin .bigger.doc-folio .tab-content {
background-size: 103.5%;
}
#workskin .bigger.doc-folio .tab-content p {
font-size: 19px;
line-height: 25px;
}
#workskin .bigger.doc-folio .tab-content p.tab-title {
font-size: 26px;
}
#workskin .bigger.doc-folio .tab-content p.tab-section {
font-size: 21px;
}
2. CODEX ↑
a) Single page ↑
An illuminated manuscript page.
→ A scrollbar will appear if the content exceeds 500px in height.
- You can adjust this value by changing
max-heightin#workskin .codex-contentin the CSS, or remove it entirely by settingmax-heighttounset. - To enforce a fixed height regardless of content length (for a consistent page format) use
heightinstead ofmax-height.
→ To add a decorative drop cap to the first letter of a paragraph: Give it the class initial.
Full CSS (includes all the following demos — HTML follows each demo)
Show CSS
/* ============================================================
CODEX — SINGLE PAGE
============================================================ */
#workskin .codex {
max-width: 38em;
margin: 20px auto;
padding: 3em 4em;
box-sizing: border-box;
position: relative;
color: #2e2416;
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
font-style: italic;
background-color: rgb(247 242 234);
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
border-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/codex-border.png") 27% round;
border-image-outset: 10px;
border-image-width: 80px;
filter: drop-shadow(2px 4px 6px #464646);
}
#workskin .codex p {
margin: 15px auto;
}
#workskin .codex-title {
text-align: center;
font-style: normal;
font-variant: small-caps;
font-size: 1.4em;
padding-block: 15px;
border-block: 5px double #b2b2b2;
}
#workskin .codex-content {
scrollbar-color: #808297 transparent;
padding: 5px;
max-height: 500px;
overflow-y: auto;
box-sizing: border-box;
}
#workskin .codex-content p {
text-align: justify;
line-height: 1.4em;
}
#workskin .codex-content > p:first-of-type,
#workskin .codex-content > p.codex-img-left:first-of-type + p,
#workskin .codex-content > p.codex-img-right:first-of-type + p {
margin-top: 0;
}
#workskin .codex-content p:last-of-type {
margin-bottom: 0;
}
#workskin .codex-folio {
border-top: 2px solid #808080;
padding-top: 10px;
font-size: 12px;
font-style: normal;
text-align: right;
}
#workskin .codex .initial::first-letter {
font-family: 'Georgia', serif;
font-weight: bold;
font-style: italic;
font-size: 3.2rem;
float: left;
line-height: 1;
margin-top: 2px;
margin-right: 8px;
color: #616acc;
}
#workskin .codex .accent {
color: #616acc;
}
#workskin .codex-content hr {
border: 0;
height: 1px;
background: #808080;
width: 70%;
margin: 30px auto;
position: relative;
overflow: visible;
}
#workskin .codex-content hr::after {
content: "♦\FE0E";
display: inline-block;
position: absolute;
height: 0;
line-height: 0;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
background: transparent;
padding: 0 10px;
color: #616acc;
font-size: 14px;
}
/* ============================================================
CODEX — IMAGES
No need to add #workskin .img-float-clear again if already included via another component's image css
============================================================ */
#workskin .codex-content > p:has(img) {
margin: 0;
}
#workskin .codex-content > p.codex-img-left img {
margin-right: 10px;
float: left;
}
#workskin .codex-content > p.codex-img-right img {
margin-left: 10px;
float: right;
}
#workskin .codex-content .img-float-clear + p,
#workskin .codex-content .img-float-clear + p.codex-img-left + p,
#workskin .codex-content .img-float-clear + p.codex-img-right + p {
margin-top: 0;
}
#workskin .img-float-clear {
clear: both;
}Basic codex page
On the Nature of Wards
Folio XII: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Restricted Archive — Wing III
HTML
<div class="codex">
<p class="codex-title">Title of the Page</p>
<div class="codex-content">
<p class="initial">First paragraph here.</p>
<hr>
<p>Another paragraph here.</p>
</div>
<p class="codex-folio">Folio Number — Archive Name</p>
</div>Codex page with image
→ Add an image to your page:
- Find the
<p class="codex-img-left"><img width="40%" src="img-url-here"></p>tag, swap in your own URL and adjust the width to your liking. - A mirrored
codex-img-rightclass is also available if you'd rather float the image to the right. - To use a centered image:
<p align="center"><img width="80%" src="img-url-here"></p>. Adjust the width however you like.
Demo
The Cartographer's Ward

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Restricted Archive — Wing III
HTML
<div class="codex">
<p class="codex-title">Title of the Page</p>
<div class="codex-content">
<p class="codex-img-left">
<img width="40%" src="img-url-here">
</p>
<p class="initial">First paragraph here.</p>
<div class="img-float-clear"></div>
<p>Another paragraph here.</p>
</div>
<p class="codex-folio">Folio Number — Archive Name</p>
</div>
b) Manuscript (tab view) ↑
A decorative cover panel and a sidebar of hoverable tabs that reveal your content.
The full code follows the demos (covers both standard and bigger variants).
Standard demo
The Grand Codex
Chronicles of World Lore and Knowledge
Bigger demo
The Grand Codex
Chronicles of World Lore and Knowledge
Full code
→ Mobile Compatibility: Note that the layout does not adapt perfectly to smaller screens. The content will overflow on mobile. However, the standard version remains significantly more readable on mobile screens than the .bigger modifier version.
→ Modifier: To switch to larger dimensions, add the class bigger alongside the main class (example: <div class="doc-codex bigger">).
→ How it works: To add a tab, copy the whole tab block (from <!-- TAB START --> to <!-- TAB END -->) and paste it right after the previous one. Since this can be a bit tricky at first, the available classes, adding images, customizing things, and how the code works more broadly are explained in detail at the end of this work.
HTML
<div class="doc-codex">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Subtitle</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START -->
<div class="tab">
<!-- TAB BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Label here.</p>
</div>
</div>
<!-- TAB BUTTON END -->
<!-- TAB CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">
<span class="accent">Tab 1:</span>
Tab title here.
</p>
<p class="tab-section">Section title here.</p>
<p class="img-left">
<img width="40%" src="img-url-here">
</p>
<p>Paragraph here.</p>
<div class="img-float-clear"></div>
<hr>
<p class="tab-section">Another section title here.</p>
<p>Another paragraph here.</p>
</div>
</div>
<!-- TAB CONTENT END -->
</div>
<!-- TAB END -->
</div>
</div>Show CSS
/* ------------------------------------------------------------
SCROLLBAR
------------------------------------------------------------ */
#workskin .doc-codex * {
scrollbar-color: #808297 transparent;
}
/* ------------------------------------------------------------
CONTAINER
Outer wrapper, cover and panels dimensions.
------------------------------------------------------------ */
#workskin .doc-codex {
width: 565px;
margin: auto;
position: relative;
overflow: hidden;
}
#workskin .doc-codex .doc-cover,
#workskin .doc-codex .tab-panel {
width: 375px;
}
#workskin .doc-codex,
#workskin .doc-codex .doc-cover,
#workskin .doc-codex .tab-panel {
height: 458px;
background-color: rgb(247 242 234);
box-sizing: border-box;
}
/* Padding & transparent border */
#workskin .doc-codex .doc-cover {
padding: 58px 56px;
}
#workskin .doc-codex .tab-panel {
border-style: solid;
border-color: transparent;
border-width: 58px 56px;
}
/* ------------------------------------------------------------
COVER
Decorative left panel with background image.
------------------------------------------------------------ */
#workskin .doc-codex .doc-cover {
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 0;
top: 0;
opacity: 0.9;
z-index: 1;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-cover-codex.jpg");
background-size: contain;
background-repeat: no-repeat;
}
/* ------------------------------------------------------------
COVER — DECORATIVE IMAGE
Icon or illustration displayed on the cover panel.
------------------------------------------------------------ */
#workskin .doc-codex .doc-img {
width: 170px;
height: 95px;
margin-block: 8%;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/codex-icon.png");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
filter: brightness(1.2);
}
/* ------------------------------------------------------------
COVER — HEADLINE
Title and subtitle block displayed on the cover image.
------------------------------------------------------------ */
/* Headline */
#workskin .doc-codex .doc-headline {
width: 100%;
padding-inline: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
box-sizing: border-box;
}
#workskin .doc-codex .doc-headline p {
margin: 0;
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
color: #2e2416;
text-align: center;
}
/* Title */
#workskin .doc-codex .doc-headline p.doc-title {
padding-bottom: 15px;
padding-inline: 10px;
font-size: 23px;
font-variant: small-caps;
line-height: 1;
}
/* Subtitle */
#workskin .doc-codex .doc-headline p.doc-subtitle {
padding-top: 15px;
padding-inline: 15px;
font-size: 15px;
line-height: 1;
}
/* ------------------------------------------------------------
SIDEBAR
Right column holding all tab buttons.
Acts as positioning context for all panels.
overflow: hidden clips panels at rest;
:has(.tab:hover) reveals them on hover.
------------------------------------------------------------ */
#workskin .doc-codex .sidebar {
position: absolute;
right: 0;
top: 0;
width: 190px;
height: 100%;
display: flex;
flex-direction: column;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
z-index: 10;
overflow: hidden;
}
#workskin .doc-codex .sidebar:has(.tab:hover) {
overflow: visible;
}
/* ------------------------------------------------------------
TAB
Individual tab item.
------------------------------------------------------------ */
#workskin .doc-codex .tab {
flex: 1;
overflow: hidden;
z-index: 10;
}
#workskin .doc-codex .tab:hover {
overflow: visible;
z-index: 20;
}
/* ------------------------------------------------------------
TAB — BUTTON
Visible area. Reveals the panel on hover.
------------------------------------------------------------ */
#workskin .doc-codex .tab-btn {
display: block;
width: 100%;
height: 100%;
border: ridge rgba(220, 210, 190, 0.8);
background-position: center center;
cursor: pointer;
transition: filter 300ms ease-in-out, opacity 300ms ease-in-out;
box-sizing: border-box;
position: relative;
z-index: 5;
opacity: 0.7;
}
#workskin .doc-codex .tab:hover .tab-btn {
opacity: 0.85;
filter: saturate(40%);
}
/* ------------------------------------------------------------
TAB BUTTON IMAGES
Default image shared by all tabs. Override per tab using
:nth-child(N) to assign a different image to each category.
Example:
#workskin .doc-codex .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
------------------------------------------------------------ */
#workskin .doc-codex .tab-btn {
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/codex.jpg");
background-position: 16% 15%;
background-size: 200%;
}
/* Per-tab overrides (uncomment and fill in URLs):
#workskin .doc-codex .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-codex .tab:nth-child(2) .tab-btn {
background-image: url("img-url-here");
background-size: cover;
}
#workskin .doc-codex .tab:nth-child(3) .tab-btn {
background-image: url("img-url-here");
background-size: cover;
}
#workskin .doc-codex .tab:nth-child(4) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-codex .tab:nth-child(5) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* ------------------------------------------------------------
TAB — LABEL
Text overlay at the bottom of each tab button.
------------------------------------------------------------ */
#workskin .doc-codex .tab-label {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 6;
box-sizing: border-box;
background-color: rgba(247, 242, 234, 0.88);
border-top: 1px solid rgba(170, 150, 120, 0.35);
box-shadow: 0 -1px 5px #373737;
border-radius: 0 25px;
}
/* Label text */
#workskin .doc-codex .tab-label p {
margin-block: 7px;
font-family: 'Lucida Grande', 'Lucida Sans Unicode', sans-serif;
font-size: 12px;
font-weight: bold;
font-variant: small-caps;
text-align: center;
line-height: 1.3;
letter-spacing: 0.02em;
color: #2e2416;
}
#workskin .doc-codex .tab-label .red {
color: #8d0000;
}
/* ------------------------------------------------------------
TAB — PANEL
Scrollable content panel revealed on tab hover.
Positioned against .sidebar (its stacking context).
top: 0 keeps it flush with the container top regardless
of which tab is hovered.
------------------------------------------------------------ */
#workskin .doc-codex .tab-panel {
position: absolute;
top: 0;
right: 100%;
z-index: 19;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
background-size: 100%;
background-repeat: repeat;
background-clip: content-box;
overflow: auto;
display: none;
}
#workskin .doc-codex .tab:hover .tab-panel {
display: block;
}
/* ------------------------------------------------------------
TAB — PANEL CONTENT
Inner content area.
------------------------------------------------------------ */
#workskin .doc-codex .tab-content {
width: 100%;
padding: 12px 14px;
box-sizing: border-box;
position: relative;
}
/* Drop cap — applied automatically to the first paragraph in .doc-codex .tab-content
that is not a title or section header, or manually via .initial on any paragraph. */
#workskin .doc-codex .initial::first-letter,
#workskin .doc-codex .tab-content > p:not(#workskin .tab-title, #workskin .tab-section):first-of-type::first-letter {
font-family: 'Georgia', serif;
font-weight: bold;
font-style: italic;
font-size: 3.5rem;
float: left;
line-height: 1;
margin-top: 2px;
margin-right: 8px;
color: #616acc;
}
#workskin .doc-codex .tab-content p {
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
color: #2e2416;
font-style: italic;
text-align: justify;
font-size: 14px;
line-height: 20px;
}
#workskin .doc-codex .tab-content p.tab-title {
text-align: center;
font-size: 18px;
padding-block: 15px;
border-block: 5px double #b2b2b2;
}
#workskin .doc-codex .tab-content p.tab-section {
font-size: 16px;
}
/* Images */
#workskin .doc-codex .tab-content > p.img-left img {
margin-right: 10px;
float: left;
}
#workskin .doc-codex .tab-content > p.img-right img {
margin-left: 10px;
float: right;
}
#workskin .doc-codex .tab-content .img-float-clear + p,
#workskin .doc-codex .tab-content .img-float-clear + p.img-left + p,
#workskin .doc-codex .tab-content .img-float-clear + p.img-right + p {
margin-top: 0;
}
#workskin .doc-codex .tab-content .img-float-clear {
clear: both;
}
/* Accent colors */
#workskin .doc-codex .accent {
color: #616acc; /* blue */
}
/* <hr> separators */
#workskin .doc-codex .doc-headline .doc-title-separator,
#workskin .doc-codex .tab-content hr {
border: 0;
height: 1px;
background: #808080;
width: 70%;
position: relative;
overflow: visible;
}
#workskin .doc-codex .doc-headline .doc-title-separator {
margin: 20px auto;
}
#workskin .doc-codex .tab-content hr {
margin: 30px auto;
}
#workskin .doc-codex .doc-headline .doc-title-separator::after,
#workskin .doc-codex .tab-content hr::after {
content: "♦\FE0E";
display: inline-block;
position: absolute;
height: 0;
line-height: 0;
margin-top: 1px;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
background: transparent;
padding: 0 10px;
color: #616acc;
font-size: 14px;
}
/* ------------------------------------------------------------
BIGGER MODIFIER
Add .bigger to switch to larger dimensions.
All overrides for .bigger are grouped here.
Example: <div class="doc-codex bigger">
------------------------------------------------------------ */
/* Container — Outer wrapper, cover and panels dimensions. */
#workskin .bigger.doc-codex {
width: 765px;
}
#workskin .bigger.doc-codex,
#workskin .bigger.doc-codex .doc-cover,
#workskin .bigger.doc-codex .tab-panel {
height: 702px;
}
#workskin .bigger.doc-codex .doc-cover,
#workskin .bigger.doc-codex .tab-panel {
width: 575px;
}
#workskin .bigger.doc-codex .doc-cover {
padding: 88px 86px;
}
#workskin .bigger.doc-codex .tab-panel {
border-style: solid;
border-color: transparent;
border-width: 88px 86px;
}
/* Cover image and margin */
#workskin .bigger.doc-codex .doc-img {
width: 200px;
height: 125px;
margin-block: 12%;
}
/* Headline */
#workskin .bigger.doc-codex .doc-headline p.doc-title {
font-size: 30px;
}
#workskin .bigger.doc-codex .doc-headline p.doc-subtitle {
font-size: 17px;
}
/* Tab labels */
#workskin .bigger.doc-codex .tab-label p {
font-size: 13px;
}
/* Tab button images — add per-tab overrides here, one entry per tab:
.tab:nth-child(1) for the first button, .tab:nth-child(2) for the second button, and so on.
Example:
#workskin .bigger.doc-codex .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* Tab content — Font size */
#workskin .bigger.doc-codex .initial::first-letter,
#workskin .bigger.doc-codex .tab-content > p:not(#workskin .tab-title, #workskin .tab-section):first-of-type::first-letter {
font-size: 4rem;
}
#workskin .bigger.doc-codex .tab-content p {
font-size: 16px;
line-height: 22px;
}
#workskin .bigger.doc-codex .tab-content p.tab-title {
font-size: 20px;
}
#workskin .bigger.doc-codex .tab-content p.tab-section {
font-size: 18px;
}
3. BOOK ↑
a) Back cover/Single page/Cover animation ↑
A dark, ornate book cover with a decorative border.
→ A scrollbar will appear if the content exceeds 500px in height (this applies to all back cover and inner parchment page variants).
- You can adjust this value by changing
max-heightin#workskin .book-contentin the CSS, or remove it entirely by settingmax-heighttounset. - To enforce a fixed height regardless of content length (for a consistent page or cover format) use
heightinstead ofmax-height.
Full CSS (includes all the following demos — HTML follows each demo)
Show CSS
/* ============================================================
BOOK — BACK COVER
============================================================ */
#workskin .book {
max-width: 38em;
margin: 20px auto;
padding: 5em 2em;
box-sizing: border-box;
position: relative;
color: #d8c8af;
font-family: 'Lucida Grande', 'Lucida Sans Unicode', sans-serif;
background: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-cover-texture.png") top left;
background-color: #180905;
border-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-border.png") 45% round;
border-image-outset: 20px;
border-image-width: 130px;
filter: drop-shadow(2px 4px 6px #464646) contrast(0.9);
}
#workskin .book p {
margin: 15px auto;
}
#workskin .book p.book-title {
font-size: 1.1em;
letter-spacing: 0.1em;
font-weight: bold;
text-transform: uppercase;
text-shadow: 2px 2px 2px black;
border-bottom: 2px solid #887777;
padding-bottom: 5px;
}
#workskin .book-content {
scrollbar-color: #978f80 transparent;
padding: 5px;
max-height: 500px;
overflow-y: auto;
box-sizing: border-box;
}
#workskin .book-content p {
line-height: 1.3em;
}
#workskin .book-content > p:first-of-type,
#workskin .book-content > p.book-img-left:first-of-type + p,
#workskin .book-content > p.book-img-right:first-of-type + p {
margin-top: 0;
}
#workskin .book-content p:last-of-type {
margin-bottom: 0;
}
#workskin .book-edition {
border-top: 2px solid #887777;
padding-top: 10px;
font-size: 12px;
text-align: right;
}
/* Accent color on cover + back cover */
#workskin .book .accent,
#workskin .book-cover .accent {
color: #cfbc64; /* yellow */
}
/* <hr> separator */
#workskin .book hr,
#workskin .book-headline .book-title-separator {
border: 0;
height: 1px;
background: #808080;
width: 70%;
position: relative;
overflow: visible;
}
#workskin .book hr {
margin: 30px auto;
}
#workskin .book-headline .book-title-separator {
margin: 20px auto;
}
#workskin .book hr::after,
#workskin .book-headline .book-title-separator::after {
content: "♦\FE0E";
display: inline-block;
position: absolute;
height: 0;
line-height: 0;
margin-top: 1px;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
background: transparent;
padding: 0 10px;
color: #cfbc64;
font-size: 14px;
}
/* ============================================================
BOOK — INNER PAGE
============================================================ */
#workskin .book .parchment {
max-width: 40em;
margin: auto;
color: black;
font-family: 'Lucida Grande', 'Lucida Sans Unicode', sans-serif;
background: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
padding: 1em 1.3em;
position: relative;
box-sizing: border-box;
}
#workskin .book .parchment p.book-title {
text-shadow: none;
}
/* Accent color on parchment page */
#workskin .book .parchment .accent,
#workskin .book-cover .parchment .accent {
color: #a96525;
}
/* <hr> separator */
#workskin .book .parchment hr::after {
color: #a96525;
}
/* ============================================================
BOOK — COVER ANIMATION
============================================================ */
#workskin .cover-animation {
width: 40em;
margin: 20px auto;
overflow: hidden;
position: relative;
}
#workskin .cover-animation .book-cover,
#workskin .cover-animation .book {
width: 38em;
margin: 20px auto;
padding: 5em 2em;
box-sizing: border-box;
position: relative;
color: #d8c8af;
font-family: 'Lucida Grande', 'Lucida Sans Unicode', sans-serif;
background: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-cover-texture.png") top left;
background-color: #180905;
border-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-border.png") 45% round;
border-image-outset: 20px;
border-image-width: 130px;
filter: contrast(0.9);
}
#workskin .cover-animation .book-cover {
position: absolute;
top: 0;
bottom: 0;
left: 50%;
transform: translate(-50%);
margin: 20px 0;
z-index: 1;
transition: 500ms ease-in-out;
}
#workskin .cover-animation:hover .book-cover {
left: -100%;
}
#workskin .cover-animation .book-cover .book-img {
width: 160px;
height: 110px;
margin-inline: auto;
margin-block: 12%;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-cover-image.gif");
background-size: cover;
background-position: center;
border-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/frame.png") 30% round;
border-image-outset: 25px;
border-image-width: 51px;
filter: contrast(1.1);
}
#workskin .cover-animation .book-cover .book-headline {
padding-inline: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
#workskin .cover-animation .book-cover .book-headline p {
margin: 0;
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
text-align: center;
color: #d8c8af;
}
/* Title */
#workskin .cover-animation .book-cover .book-headline p.book-title {
padding-bottom: 15px;
padding-inline: 10px;
font-size: 30px;
line-height: 1;
font-variant: small-caps;
}
/* Subtitle */
#workskin .cover-animation .book-cover .book-headline p.book-subtitle {
padding-top: 15px;
padding-inline: 15px;
font-size: 17px;
line-height: 1;
}
/* Fixed book content height */
#workskin .cover-animation .book-content {
height: 420px;
}
/* ============================================================
BOOK — IMAGES
No need to add #workskin .img-float-clear again if already included via another component's image css
============================================================ */
#workskin .book-content > p:has(img) {
margin: 0;
filter: brightness(0.8);
}
#workskin .book-content > p.book-img-left img {
margin-right: 10px;
float: left;
}
#workskin .book-content > p.book-img-right img {
margin-left: 10px;
float: right;
}
#workskin .book-content .img-float-clear + p,
#workskin .book-content .img-float-clear + p.book-img-left + p,
#workskin .book-content .img-float-clear + p.book-img-right + p {
margin-top: 0;
}
#workskin .img-float-clear {
clear: both;
}Basic back cover
Advanced Potion-Making
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Sixth Edition — Published by Obscurus Books, London
HTML
<div class="book">
<p class="book-title">Title of the Book</p>
<div class="book-content">
<p>First paragraph here.</p>
<p>Another paragraph here.</p>
</div>
<p class="book-edition">First Edition — 1998</p>
</div>Back cover with image
→ Add an image to your back cover:
- Find the
<p class="book-img-left"><img width="40%" src="img-url-here"></p>tag, swap in your own URL and adjust the width to your liking. - A mirrored
book-img-rightclass is also available if you'd rather float the image to the right. If you do, you'll probably want to justify the text in#workskin .book-content pusingtext-align: justify;for a cleaner look. - To use a centered image:
<p align="center"><img width="80%" src="img-url-here"></p>. Adjust the width however you like.
Demo
Advanced Potion-Making

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Sixth Edition — Published by Obscurus Books, London
HTML
<div class="book">
<p class="book-title">Title of the Book</p>
<div class="book-content">
<p class="book-img-left">
<img width="40%" src="img-url-here">
</p>
<p>First paragraph here.</p>
<p>Another paragraph here.</p>
<div class="img-float-clear"></div>
</div>
<p class="book-edition">First Edition — 1998</p>
</div>Book with inner parchment page
Foreword
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Sixth Edition — Published by Obscurus Books, London
HTML
<div class="book">
<div class="parchment">
<p class="book-title">Chapter One</p>
<div class="book-content">
<p>First paragraph here.</p>
<p>Another paragraph here.</p>
</div>
<p class="book-edition">First Edition — 1998</p>
</div>
</div>Cover animation
Variant with a cover that slides open on hover to reveal the inner page content.
→ To change the cover image: Find the background-image property inside #workskin .cover-animation .book-cover .book-img in the CSS and replace the URL with your own image.
→ In this specific variant, the book content height is fixed at 420px: a scrollbar will appear if the content exceeds this height. To adjust it, change the height value in #workskin .cover-animation .book-content in the CSS.
→ Mobile compatibility: It will overflow on smaller screens, though the content remains readable.
Demo
The Book of shadows
VOLUME I
A Collection of Ancient Lore and Forgotten Wisdom
Foreword
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Sixth Edition — Published by Obscurus Books, London
HTML
<div class="cover-animation">
<!-- BOOK COVER START -->
<div class="book-cover">
<div class="book-img"></div>
<div class="book-headline">
<p class="book-title">Title</p>
<div class="book-title-separator"></div>
<p class="book-subtitle"><span class="accent">VOLUME I</span></p>
<p class="book-subtitle">Subtitle</p>
</div>
</div>
<!-- BOOK COVER END -->
<div class="book">
<div class="parchment">
<p class="book-title">Chapter One</p>
<div class="book-content">
<p>First paragraph here.</p>
<p>Another paragraph here.</p>
</div>
<p class="book-edition">First Edition — 1998</p>
</div>
</div>
</div>
b) Volume (tab view) ↑
A decorative cover panel and a sidebar of hoverable tabs that reveal your content.
The full code follows the demos (covers both standard and bigger variants).
Standard demo
The Book of shadows
VOLUME I
A Collection of Ancient Lore and Forgotten Wisdom
Bigger demo
The Book of shadows
VOLUME I
A Collection of Ancient Lore and Forgotten Wisdom
Full code
→ Mobile Compatibility: Note that the layout does not adapt perfectly to smaller screens. The content will overflow on mobile. However, the standard version remains significantly more readable on mobile screens than the .bigger modifier version.
→ Modifier: To switch to larger dimensions, add the class bigger alongside the main class (example: <div class="doc-book bigger">).
→ How it works: To add a tab, copy the whole tab block (from <!-- TAB START --> to <!-- TAB END -->) and paste it right after the previous one. Since this can be a bit tricky at first, the available classes, adding images, customizing things, and how the code works more broadly are explained in detail at the end of this work.
HTML
<div class="doc-book">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Subtitle</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START -->
<div class="tab">
<!-- TAB BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Label here.</p>
</div>
</div>
<!-- TAB BUTTON END -->
<!-- TAB CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">
<span class="accent">Tab 1:</span>
Tab title here.
</p>
<p class="tab-section">Section title here.</p>
<p class="img-left">
<img width="40%" src="img-url-here">
</p>
<p>Paragraph here.</p>
<div class="img-float-clear"></div>
<hr>
<p class="tab-section">Another section title here.</p>
<p>Another paragraph here.</p>
</div>
</div>
<!-- TAB CONTENT END -->
</div>
<!-- TAB END -->
</div>
</div>Show CSS
/* ------------------------------------------------------------
SCROLLBAR
------------------------------------------------------------ */
#workskin .doc-book * {
scrollbar-color: #76675b transparent;
}
/* ------------------------------------------------------------
CONTAINER
Outer wrapper, cover and panels dimensions.
------------------------------------------------------------ */
#workskin .doc-book {
width: 565px;
margin: auto;
position: relative;
overflow: hidden;
}
#workskin .doc-book .doc-cover,
#workskin .doc-book .tab-panel {
width: 375px;
}
#workskin .doc-book,
#workskin .doc-book .doc-cover,
#workskin .doc-book .tab-panel {
height: 445px;
background-color: #180905;
box-sizing: border-box;
}
/* Padding & transparent border */
#workskin .doc-book .doc-cover {
padding: 50px 43px;
}
#workskin .doc-book .tab-panel {
border-style: solid;
border-color: transparent;
border-width: 50px 43px;
}
/* ------------------------------------------------------------
COVER
Decorative left panel with background image.
------------------------------------------------------------ */
#workskin .doc-book .doc-cover {
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 0;
top: 0;
opacity: 0.9;
z-index: 1;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-cover-texture.png");
background-repeat: repeat;
border-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-border.png") 45% round;
border-image-outset: 7px;
border-image-width: 100px;
filter: contrast(0.9);
}
/* ------------------------------------------------------------
COVER — DECORATIVE IMAGE
Icon or illustration displayed on the cover panel.
------------------------------------------------------------ */
#workskin .doc-book .doc-img {
width: 110px;
height: 80px;
margin-block: 12%;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-cover-image.gif");
background-size: cover;
background-position: center;
border-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/frame.png") 30% round;
border-image-outset: 15px;
border-image-width: 36px;
filter: contrast(1.1);
}
/* ------------------------------------------------------------
COVER — HEADLINE
Title and subtitle block displayed on the cover image.
------------------------------------------------------------ */
/* Headline */
#workskin .doc-book .doc-headline {
width: 100%;
padding-inline: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
#workskin .doc-book .doc-headline p {
margin: 0;
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
text-align: center;
color: #d8c8af;
}
/* Title */
#workskin .doc-book .doc-headline p.doc-title {
padding-bottom: 15px;
padding-inline: 10px;
font-size: 23px;
line-height: 1;
font-variant: small-caps;
}
/* Subtitle */
#workskin .doc-book .doc-headline p.doc-subtitle {
padding-top: 15px;
padding-inline: 15px;
font-size: 15px;
line-height: 1;
}
/* ------------------------------------------------------------
SIDEBAR
Right column holding all tab buttons.
Acts as positioning context for all panels.
overflow: hidden clips panels at rest;
:has(.tab:hover) reveals them on hover.
------------------------------------------------------------ */
#workskin .doc-book .sidebar {
position: absolute;
right: 0;
top: 0;
width: 190px;
height: 100%;
display: flex;
flex-direction: column;
background-color: #634037;
z-index: 10;
overflow: hidden;
}
#workskin .doc-book .sidebar:has(.tab:hover) {
overflow: visible;
}
/* ------------------------------------------------------------
TAB
Individual tab item.
------------------------------------------------------------ */
#workskin .doc-book .tab {
flex: 1;
overflow: hidden;
z-index: 10;
}
#workskin .doc-book .tab:hover {
overflow: visible;
z-index: 20;
}
/* ------------------------------------------------------------
TAB — BUTTON
Visible area. Reveals the panel on hover.
------------------------------------------------------------ */
#workskin .doc-book .tab-btn {
display: block;
width: 100%;
height: 100%;
border: ridge #37231e;
background-position: center center;
cursor: pointer;
transition: filter 300ms ease-in-out, opacity 300ms ease-in-out;
box-sizing: border-box;
position: relative;
z-index: 5;
opacity: 0.7;
filter: contrast(1.2) saturate(50%);
}
#workskin .doc-book .tab:hover .tab-btn {
opacity: 0.85;
filter: contrast(1.2) saturate(40%);
}
/* ------------------------------------------------------------
TAB BUTTON IMAGES
Default image shared by all tabs. Override per tab using
:nth-child(N) to assign a different image to each category.
Example:
#workskin .doc-book .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
------------------------------------------------------------ */
#workskin .doc-book .tab-btn {
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/bookshelf.jpg");
background-position: right bottom;
background-size: 200%;
}
/* Per-tab overrides (uncomment and fill in URLs):
#workskin .doc-book .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-book .tab:nth-child(2) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-book .tab:nth-child(3) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-book .tab:nth-child(4) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-book .tab:nth-child(5) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* ------------------------------------------------------------
TAB — LABEL
Text overlay at the bottom of each tab button.
------------------------------------------------------------ */
#workskin .doc-book .tab-label {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 6;
box-sizing: border-box;
background-color: #180905;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/book-cover-texture.png");
background-size: 100%;
background-repeat: repeat;
border-top: 1px solid rgba(170, 150, 120, 0.35);
box-shadow: 0 0 10px #141414;
}
/* Label text */
#workskin .doc-book .tab-label p {
margin-block: 7px;
font-family: "Georgia", "Apple Chancery", "Palatino Linotype", serif;
font-size: 12px;
font-style: italic;
font-weight: bold;
text-align: center;
line-height: 1.3;
letter-spacing: 0.02em;
color: rgba(247, 242, 234, 0.88);
}
#workskin .doc-book .tab-label .red {
color: #b30000;
}
/* ------------------------------------------------------------
TAB — PANEL
Scrollable content panel revealed on tab hover.
Positioned against .sidebar (its stacking context).
top: 0 keeps it flush with the container top regardless
of which tab is hovered.
------------------------------------------------------------ */
#workskin .doc-book .tab-panel {
position: absolute;
top: 0;
right: 380%;
z-index: 19;
background-color: rgb(247 242 234);
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
background-size: 100%;
background-repeat: repeat;
background-clip: content-box;
overflow: auto;
transition: 300ms ease-in-out;
}
#workskin .doc-book .tab:hover .tab-panel {
right: 100%;
filter: drop-shadow(0 0 50px black);
}
/* ------------------------------------------------------------
TAB — PANEL CONTENT
Inner content area.
------------------------------------------------------------ */
#workskin .doc-book .tab-content {
width: 100%;
padding: 12px 14px;
box-sizing: border-box;
position: relative;
}
/* Drop cap — applied automatically to the first paragraph in .doc-book .tab-content
that is not a title or section header, or manually via .initial on any paragraph. */
#workskin .doc-book .initial::first-letter,
#workskin .doc-book .tab-content > p:not(#workskin .tab-title, #workskin .tab-section):first-of-type::first-letter {
font-family: 'Georgia', serif;
font-weight: bold;
font-style: italic;
font-size: 3.5rem;
float: left;
line-height: 1;
margin-top: 2px;
margin-right: 8px;
color: #a96525;
}
#workskin .doc-book .tab-content p {
font-family: "Apple Chancery", "Palatino Linotype", "Georgia", serif;
color: #2e2416;
text-align: justify;
font-size: 14px;
line-height: 20px;
}
#workskin .doc-book .tab-content p.tab-title {
text-align: center;
font-size: 18px;
padding-block: 15px;
border-block: 5px double #b2b2b2;
}
#workskin .doc-book .tab-content p.tab-section {
font-size: 16px;
}
/* Images */
#workskin .doc-book .tab-content > p.img-left img {
margin-right: 10px;
float: left;
}
#workskin .doc-book .tab-content > p.img-right img {
margin-left: 10px;
float: right;
}
#workskin .doc-book .tab-content .img-float-clear + p,
#workskin .doc-book .tab-content .img-float-clear + p.img-left + p,
#workskin .doc-book .tab-content .img-float-clear + p.img-right + p {
margin-top: 0;
}
#workskin .doc-book .tab-content .img-float-clear {
clear: both;
}
/* Accent colors */
#workskin .doc-book .accent {
color: #cfbc64; /* yellow on cover */
}
#workskin .doc-book .tab-content .accent {
color: #a96525; /* darker on pages */
}
/* <hr> separator */
#workskin .doc-book .doc-headline .doc-title-separator,
#workskin .doc-book .tab-content hr {
border: 0;
height: 1px;
background: #808080;
width: 70%;
position: relative;
overflow: visible;
}
#workskin .doc-book .doc-headline .doc-title-separator {
margin: 20px auto;
}
#workskin .doc-book .tab-content hr {
margin: 30px auto;
}
#workskin .doc-book .doc-headline .doc-title-separator::after,
#workskin .doc-book .tab-content hr::after {
content: "♦\FE0E";
display: inline-block;
position: absolute;
height: 0;
line-height: 0;
margin-top: 1px;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
background: transparent;
padding: 0 10px;
color: #cfbc64;
font-size: 14px;
}
#workskin .doc-book .tab-content hr::after {
color: #a96525;
}
/* ------------------------------------------------------------
BIGGER MODIFIER
Add .bigger to switch to larger dimensions.
All overrides for .bigger are grouped here.
Example: <div class="doc-book bigger">
------------------------------------------------------------ */
/* Container — Outer wrapper, cover and panels dimensions. */
#workskin .bigger.doc-book {
width: 765px;
}
#workskin .bigger.doc-book,
#workskin .bigger.doc-book .doc-cover,
#workskin .bigger.doc-book .tab-panel {
height: 682px;
}
#workskin .bigger.doc-book .doc-cover,
#workskin .bigger.doc-book .tab-panel {
width: 575px;
}
#workskin .bigger.doc-book .doc-cover {
padding: 70px 50px;
border-image-outset: 8px;
border-image-width: 130px;
}
#workskin .bigger.doc-book .tab-panel {
border-style: solid;
border-color: transparent;
border-width: 70px 50px;
}
/* Cover image and margin */
#workskin .bigger.doc-book .doc-img {
width: 160px;
height: 110px;
margin-block: 12%;
border-image-outset: 25px;
border-image-width: 51px;
}
/* Headline */
#workskin .bigger.doc-book .doc-headline p.doc-title {
font-size: 30px;
}
#workskin .bigger.doc-book .doc-headline p.doc-subtitle {
font-size: 17px;
}
/* Tab buttons / labels */
#workskin .bigger.doc-book .tab-btn {
background-size: unset;
}
#workskin .bigger.doc-book .tab-label p {
font-size: 13px;
}
/* Tab button images — add per-tab overrides here, one entry per tab:
.tab:nth-child(1) for the first button, .tab:nth-child(2) for the second button, and so on.
Example:
#workskin .bigger.doc-book .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* Tab content — Font size */
#workskin .bigger.doc-book .initial::first-letter,
#workskin .bigger.doc-book .tab-content > p:not(#workskin .tab-title, #workskin .tab-section):first-of-type::first-letter {
font-size: 4rem;
}
#workskin .bigger.doc-book .tab-content p {
font-size: 15px;
line-height: 22px;
}
#workskin .bigger.doc-book .tab-content p.tab-title {
font-size: 20px;
}
#workskin .bigger.doc-book .tab-content p.tab-section {
font-size: 18px;
}
4. NEWSPAPER ↑
a) Clipping ↑
A sepia-toned newspaper layout.
→ A scrollbar will appear if the content exceeds 550px in height.
- You can adjust this value by changing
max-heightin#workskin .newspaper-contentin the CSS, or remove it entirely by settingmax-heighttounset. - To enforce a fixed height regardless of content length (for a consistent newspaper format) use
heightinstead ofmax-height.
Full CSS (includes all the following demos — HTML follows each demo)
Show CSS
/* ============================================================
NEWSPAPER — CLIPPING
============================================================ */
#workskin .newspaper {
max-width: 40em;
margin: auto;
padding: 10px 20px;
box-sizing: border-box;
position: relative;
color: black;
font-family: 'Lucida Grande', 'Lucida Sans Unicode', sans-serif;
background: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/newspaper-texture.jpg");
box-shadow: 0 0 10px #bcbcbc;
filter: sepia(40%) saturate(60%) brightness(1);
}
#workskin .newspaper p {
margin: 15px auto;
}
#workskin .newspaper-headline {
margin: 1.286em auto;
margin-top: 2em;
padding: 10px 0;
border-bottom: 2px dashed #b3a4a4;
border-top: 2px dashed #b3a4a4;
}
#workskin .newspaper-headline p {
margin: auto;
}
#workskin .newspaper-title {
font-family: "Courier New", Courier, monospace;
text-align: center;
text-transform: uppercase;
letter-spacing: 3px;
font-size: 23px;
line-height: 23px;
}
#workskin .newspaper-date {
font-family: "Courier New", Courier, monospace;
font-size: 11px;
position: absolute;
top: 1em;
}
#workskin .newspaper-content {
scrollbar-color: #978f80 transparent;
padding: 5px;
max-height: 550px;
overflow-y: auto;
box-sizing: border-box;
}
#workskin .newspaper-content p {
font-family: Garamond, "Apple Garamond", Baskerville, "Baskerville Old Face", "Hoefler Text", "Book Antiqua", "Times New Roman", Times, serif;
font-size: 18px;
line-height: 19px;
text-align: justify;
}
#workskin .newspaper-content > p:first-of-type,
#workskin .newspaper-content > p.newspaper-img-left:first-of-type + p,
#workskin .newspaper-content > p.newspaper-img-right:first-of-type + p {
margin-top: 0;
}
#workskin .newspaper-content p:last-of-type {
margin-bottom: 0;
}
#workskin .newspaper-byline {
font-family: Garamond, "Apple Garamond", Baskerville, "Baskerville Old Face", "Hoefler Text", "Book Antiqua", "Times New Roman", Times, serif;
font-size: 15px;
text-align: right;
}
#workskin .newspaper-footer {
font-family: "Courier New", Courier, monospace;
text-align: center;
font-size: 12px;
border-top: 1px solid #9d9d9d;
padding-top: 10px;
margin-bottom: 0;
}
/* ============================================================
NEWSPAPER — IMAGES
No need to add #workskin .img-float-clear again if already included via another component's image css
============================================================ */
#workskin .newspaper-content > p:has(img) {
margin: 0;
filter: sepia(1);
}
#workskin .newspaper-content > p.newspaper-img-left img {
margin-right: 10px;
float: left;
}
#workskin .newspaper-content > p.newspaper-img-right img {
margin-left: 10px;
float: right;
}
#workskin .newspaper-content .img-float-clear + p,
#workskin .newspaper-content .img-float-clear + p.newspaper-img-left + p,
#workskin .newspaper-content .img-float-clear + p.newspaper-img-right + p {
margin-top: 0;
}
#workskin .img-float-clear {
clear: both;
}Basic newspaper
Monday, 2 September 1998 — 3 Sickles
The Daily Prophet
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Nam sit amet pulvinar metus, a pretium metus. Morbi lobortis eu turpis et rhoncus. Mauris at metus mattis, fermentum risus non, vulputate risus. Phasellus lobortis auctor lacus, vel hendrerit elit fringilla in. Ut vel diam ac eros suscipit blandit nec eget quam. Integer porttitor eros eget libero interdum tincidunt. Phasellus molestie, erat eget pharetra suscipit, eros mi malesuada justo, nec dignissim quam odio eu urna.
HTML
<div class="newspaper">
<div class="newspaper-headline">
<p class="newspaper-date">1 September 1998</p>
<p class="newspaper-title">THE DAILY PROPHET</p>
</div>
<div class="newspaper-content">
<p>First paragraph here.</p>
<p>Another paragraph here.</p>
</div>
<p class="newspaper-byline">— By Your Name</p>
<p class="newspaper-footer">— End of article —</p>
</div>Newspaper with sepia article images
→ Add an image to your article:
- Find the
<p class="newspaper-img-left"><img width="40%" src="img-url-here"></p>tag, swap in your own URL and adjust the width to your liking. - A mirrored
newspaper-img-rightclass is also available if you'd rather float the image to the right. - To use a centered image:
<p align="center"><img width="80%" src="img-url-here"></p>. Adjust the width however you like.
Demo
Monday, 2 September 1998 — 3 Sickles
The Daily Prophet

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel.

Nam sit amet pulvinar metus, a pretium metus. Morbi lobortis eu turpis et rhoncus. Mauris at metus mattis, fermentum risus non, vulputate risus. Phasellus lobortis auctor lacus, vel hendrerit elit fringilla in. Ut vel diam ac eros suscipit blandit nec eget quam. Integer porttitor eros eget libero interdum tincidunt. Phasellus molestie, erat eget pharetra suscipit, eros mi malesuada justo, nec dignissim quam odio eu urna.
HTML
<div class="newspaper">
<div class="newspaper-headline">
<p class="newspaper-date">1 September 1998</p>
<p class="newspaper-title">THE DAILY PROPHET</p>
</div>
<div class="newspaper-content">
<p class="newspaper-img-left">
<img width="40%" src="img-url-here">
</p>
<p>First paragraph here.</p>
<div class="img-float-clear"></div>
<p class="newspaper-img-right">
<img width="30%" src="img-url-here">
</p>
<p>Another paragraph here.</p>
<div class="img-float-clear"></div>
</div>
<p class="newspaper-byline">— By Rita Skeeter</p>
<p class="newspaper-footer">— End of article —</p>
</div>
b) Gazette (tab view) ↑
A decorative cover panel and a sidebar of hoverable tabs that reveal your content.
The full code follows the demos (covers both standard and bigger variants).
Standard demo
The Daily Chronicle
Special Edition
Latest Updates and Breaking News
Bigger demo
The Daily Chronicle
Special Edition
Latest Updates and Breaking News
Full code
→ Mobile Compatibility: Note that the layout does not adapt perfectly to smaller screens. The content will overflow on mobile. However, the standard version remains significantly more readable on mobile screens than the .bigger modifier version.
→ Modifier: To switch to larger dimensions, add the class bigger alongside the main class (example: <div class="doc-newspaper bigger">).
→ How it works: To add a tab, copy the whole tab block (from <!-- TAB START --> to <!-- TAB END -->) and paste it right after the previous one. Since this can be a bit tricky at first, the available classes, adding images, customizing things, and how the code works more broadly are explained in detail at the end of this work.
HTML
<div class="doc-newspaper">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Subtitle</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START -->
<div class="tab">
<!-- TAB BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Label here.</p>
</div>
</div>
<!-- TAB BUTTON END -->
<!-- TAB CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">
<span class="accent">Tab 1:</span>
Tab title here.
</p>
<p class="tab-section">Section title here.</p>
<p class="img-left">
<img width="40%" src="img-url-here">
</p>
<p>Paragraph here.</p>
<div class="img-float-clear"></div>
<hr>
<p class="tab-section">Another section title here.</p>
<p class="img-right">
<img width="30%" src="img-url-here">
</p>
<p>Another paragraph here.</p>
<div class="img-float-clear"></div>
</div>
</div>
<!-- TAB CONTENT END -->
</div>
<!-- TAB END -->
</div>
</div>Show CSS
/* ------------------------------------------------------------
SCROLLBAR
------------------------------------------------------------ */
#workskin .doc-newspaper * {
scrollbar-color: #76675b transparent;
}
/* ------------------------------------------------------------
CONTAINER
Outer wrapper, cover and panels dimensions.
------------------------------------------------------------ */
#workskin .doc-newspaper {
width: 565px;
margin: auto;
position: relative;
overflow: hidden;
}
#workskin .doc-newspaper .doc-cover,
#workskin .doc-newspaper .tab-panel {
width: 375px;
}
#workskin .doc-newspaper,
#workskin .doc-newspaper .doc-cover,
#workskin .doc-newspaper .tab-panel {
height: 444px;
background-color: rgb(247 242 234);
box-sizing: border-box;
}
/* Padding & transparent border */
#workskin .doc-newspaper .tab-panel {
border: 5px solid transparent;
}
/* ------------------------------------------------------------
COVER
Decorative left panel with background image.
------------------------------------------------------------ */
#workskin .doc-newspaper .doc-cover {
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 0;
top: 0;
opacity: 0.9;
z-index: 1;
background-color: white;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-cover-newspaper.jpg");
background-size: contain;
background-repeat: no-repeat;
padding-inline: 10px;
border: 5px double #828282;
filter: sepia(0.3) contrast(0.8);
}
/* ------------------------------------------------------------
COVER — DECORATIVE IMAGE
Icon or illustration displayed on the cover panel.
------------------------------------------------------------ */
#workskin .doc-newspaper .doc-img {
width: 170px;
height: 95px;
margin-block: 5%;
/* background-image: url("img-url-here"); */
background-size: contain;
background-repeat: no-repeat;
background-position: center;
}
/* ------------------------------------------------------------
COVER — HEADLINE
Title and subtitle block displayed on the cover image.
------------------------------------------------------------ */
/* Headline */
#workskin .doc-newspaper .doc-headline {
width: 100%;
box-sizing: border-box;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
background-color: rgba(255, 255, 255, 0.8);
padding: 30px 15px;
margin-inline: 15px;
border: 3px double #828282;
}
#workskin .doc-newspaper .doc-headline p {
margin: 0;
font-family: Garamond, "Apple Garamond", Baskerville, "Baskerville Old Face", "Hoefler Text", "Book Antiqua", "Times New Roman", Times, serif;
text-align: center;
font-weight: bold;
color: black;
}
/* Title */
#workskin .doc-newspaper .doc-headline p.doc-title {
padding-bottom: 15px;
padding-inline: 10px;
font-size: 23px;
font-variant: small-caps;
line-height: 1;
}
/* Subtitle */
#workskin .doc-newspaper .doc-headline p.doc-subtitle {
padding-top: 15px;
padding-inline: 15px;
font-size: 15px;
line-height: 1;
}
/* ------------------------------------------------------------
SIDEBAR
Right column holding all tab buttons.
Acts as positioning context for all panels.
overflow: hidden clips panels at rest;
:has(.tab:hover) reveals them on hover.
------------------------------------------------------------ */
#workskin .doc-newspaper .sidebar {
position: absolute;
right: 0;
top: 0;
width: 190px;
height: 100%;
display: flex;
flex-direction: column;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
z-index: 10;
overflow: hidden;
}
#workskin .doc-newspaper .sidebar:has(.tab:hover) {
overflow: visible;
}
/* ------------------------------------------------------------
TAB
Individual tab item.
------------------------------------------------------------ */
#workskin .doc-newspaper .tab {
flex: 1;
overflow: hidden;
z-index: 10;
}
#workskin .doc-newspaper .tab:hover {
overflow: visible;
z-index: 20;
}
/* ------------------------------------------------------------
TAB — BUTTON
Visible area. Reveals the panel on hover.
------------------------------------------------------------ */
#workskin .doc-newspaper .tab-btn {
display: block;
width: 100%;
height: 100%;
border: ridge rgba(220, 210, 190, 0.8);
background-position: center center;
cursor: pointer;
transition: filter 300ms ease-in-out, opacity 300ms ease-in-out;
box-sizing: border-box;
position: relative;
z-index: 5;
opacity: 0.7;
filter: brightness(1.3) saturate(50%);
}
#workskin .doc-newspaper .tab:hover .tab-btn {
opacity: 0.85;
filter: brightness(1) saturate(40%);
}
/* ------------------------------------------------------------
TAB BUTTON IMAGES
Default image shared by all tabs. Override per tab using
:nth-child(N) to assign a different image to each category.
Example:
#workskin .doc-newspaper .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
------------------------------------------------------------ */
#workskin .doc-newspaper .tab-btn {
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/newspaper-background.jpg");
background-position: center bottom;
background-size: 200%;
}
/* Per-tab overrides (uncomment and fill in URLs):
#workskin .doc-newspaper .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-newspaper .tab:nth-child(2) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-newspaper .tab:nth-child(3) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-newspaper .tab:nth-child(4) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-newspaper .tab:nth-child(5) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* ------------------------------------------------------------
TAB — LABEL
Text overlay at the bottom of each tab button.
------------------------------------------------------------ */
#workskin .doc-newspaper .tab-label {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 6;
box-sizing: border-box;
background-color: rgba(247, 242, 234, 0.88);
border-top: 1px solid rgba(170, 150, 120, 0.35);
box-shadow: 0 -1px 5px #373737;
}
/* Label text */
#workskin .doc-newspaper .tab-label p {
margin-block: 7px;
font-family: Garamond, "Apple Garamond", Baskerville, "Baskerville Old Face", "Hoefler Text", "Book Antiqua", "Times New Roman", Times, serif;
font-size: 12px;
text-transform: uppercase;
color: black;
font-weight: bold;
text-align: center;
line-height: 1.3;
letter-spacing: 0.02em;
}
#workskin .doc-newspaper .tab-label .red {
color: #ff0000;
}
/* ------------------------------------------------------------
TAB — PANEL
Scrollable content panel revealed on tab hover.
Positioned against .sidebar (its stacking context).
top: 0 keeps it flush with the container top regardless
of which tab is hovered.
------------------------------------------------------------ */
#workskin .doc-newspaper .tab-panel {
position: absolute;
top: 0;
right: 100%;
z-index: 19;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/newspaper-texture.jpg");
background-size: 100%;
background-repeat: repeat;
background-clip: content-box;
overflow: auto;
display: none;
}
#workskin .doc-newspaper .tab:hover .tab-panel {
display: block;
}
/* ------------------------------------------------------------
TAB — PANEL CONTENT
Inner content area.
------------------------------------------------------------ */
#workskin .doc-newspaper .tab-content {
width: 100%;
padding: 12px 14px;
box-sizing: border-box;
position: relative;
}
#workskin .doc-newspaper .tab-content p {
font-family: Garamond, "Apple Garamond", Baskerville, "Baskerville Old Face", "Hoefler Text", "Book Antiqua", "Times New Roman", Times, serif;
color: black;
font-size: 17px;
line-height: 19px;
text-align: justify;
}
#workskin .doc-newspaper .tab-content p.tab-title {
text-align: center;
font-size: 17px;
text-transform: uppercase;
letter-spacing: 2px;
padding-block: 20px;
border-block: 2px solid #ada09e;
}
#workskin .doc-newspaper .tab-content p.tab-section {
font-size: 15px;
text-transform: uppercase;
padding-bottom: 4px;
border-bottom: 1px solid #ada09e;
}
/* Images */
#workskin .doc-newspaper .tab-content > p:has(img) {
filter: saturate(0.6);
}
#workskin .doc-newspaper .tab-content > p.img-left img {
margin-right: 10px;
float: left;
}
#workskin .doc-newspaper .tab-content > p.img-right img {
margin-left: 10px;
float: right;
}
#workskin .doc-newspaper .tab-content .img-float-clear + p,
#workskin .doc-newspaper .tab-content .img-float-clear + p.img-left + p,
#workskin .doc-newspaper .tab-content .img-float-clear + p.img-right + p {
margin-top: 0;
}
#workskin .doc-newspaper .tab-content .img-float-clear {
clear: both;
}
/* Accent colors */
#workskin .doc-newspaper .accent {
color: #bd0000; /* red */
}
/* <hr> separator */
#workskin .doc-newspaper .doc-headline .doc-title-separator,
#workskin .doc-newspaper .tab-content hr {
border: 0;
border-top: 2px solid #ada09e;
width: 90%;
position: relative;
overflow: visible;
}
#workskin .doc-newspaper .doc-headline .doc-title-separator {
margin: 10px auto;
}
#workskin .doc-newspaper .tab-content hr {
margin: 35px auto;
}
/* ------------------------------------------------------------
BIGGER MODIFIER
Add .bigger to switch to larger dimensions.
All overrides for .bigger are grouped here.
Example: <div class="doc-newspaper bigger">
------------------------------------------------------------ */
/* Container — Outer wrapper, cover and panels dimensions. */
#workskin .bigger.doc-newspaper {
width: 765px;
}
#workskin .bigger.doc-newspaper,
#workskin .bigger.doc-newspaper .doc-cover,
#workskin .bigger.doc-newspaper .tab-panel {
height: 682px;
}
#workskin .bigger.doc-newspaper .doc-cover,
#workskin .bigger.doc-newspaper .tab-panel {
width: 575px;
}
/* Cover — Padding */
#workskin .bigger.doc-newspaper .doc-cover {
padding-inline: 28px;
}
/* Cover image and margin */
#workskin .bigger.doc-newspaper .doc-img {
width: 200px;
height: 125px;
margin-block: 10%;
}
/* Headline */
#workskin .bigger.doc-newspaper .doc-headline p.doc-title {
font-size: 30px;
}
#workskin .bigger.doc-newspaper .doc-headline p.doc-subtitle {
font-size: 17px;
}
/* Tab labels */
#workskin .bigger.doc-newspaper .tab-label p {
font-size: 13px;
}
/* Tab button images — add per-tab overrides here, one entry per tab:
.tab:nth-child(1) for the first button, .tab:nth-child(2) for the second button, and so on.
Example:
#workskin .bigger.doc-newspaper .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* Tab content — Font size */
#workskin .bigger.doc-newspaper .tab-content p {
font-size: 18px;
line-height: 23px;
}
#workskin .bigger.doc-newspaper .tab-content p.tab-title {
font-size: 18px;
}
#workskin .bigger.doc-newspaper .tab-content p.tab-section {
font-size: 16px;
}
5. DIARY/NOTEBOOK ↑
a) Single entry ↑
A handwritten diary page on ruled notebook paper with a red margin line.
→ The page expands to fit however much content you add (no scrollbar).
Full CSS (includes all the following demos — HTML follows each demo)
Show CSS
/* ============================================================
DIARY — SINGLE ENTRY
============================================================ */
#workskin .diary {
max-width: 38em;
margin: auto;
padding: 13px 15px;
padding-left: 75px;
box-sizing: border-box;
position: relative;
color: #0f0f3e;
font-family: "Lucida Handwriting", "Comic Sans MS", cursive;
background-image: repeating-linear-gradient(to bottom, #ffffff 0px, #ffffff 23px, #00b0d7 23px, #00b0d7 24px);
box-shadow: 0 0 10px #bcbcbc;
}
#workskin .diary::before {
content: '';
display: block;
position: absolute;
z-index: 1;
top: 0;
left: 60px;
height: 100%;
width: 1px;
background: #db4034;
}
#workskin .diary p {
margin: 0;
}
#workskin p.diary-date {
margin-top: 15px;
text-align: right;
}
#workskin .diary-content {
margin-top: 26px;
position: relative;
box-sizing: border-box;
}
#workskin .diary-content p {
font-size: 14px;
line-height: 24px;
margin-block: 24px;
}
#workskin .diary-content > p:first-of-type,
#workskin .diary-content > p.diary-img-left:first-of-type + p,
#workskin .diary-content > p.diary-img-right:first-of-type + p {
margin-top: 0;
}
#workskin .diary-content p:last-of-type {
margin-bottom: 0;
}
#workskin p.diary-signature {
margin-top: 24px;
text-align: right;
font-style: italic;
}
#workskin .diary .accent {
color: #bd0000;
}
#workskin .diary-content hr {
border: 0;
border-top: 2px solid #ff6ae0;
width: 100%;
margin-inline: auto;
margin-top: -6px;
margin-bottom: 28px;
}
/* ============================================================
DIARY — IMAGES
No need to add #workskin .img-float-clear again if already included via another component's image css
============================================================ */
#workskin .diary-content > p:has(img) {
margin: 0;
}
#workskin .diary-content > p[align="center"] img {
width: auto;
height: 136px;
}
#workskin .diary-content > p.diary-img-left img {
margin-right: 10px;
float: left;
}
#workskin .diary-content > p.diary-img-right img {
margin-left: 10px;
float: right;
}
#workskin .diary-content .img-float-clear + p,
#workskin .diary-content .img-float-clear + p.diary-img-left + p,
#workskin .diary-content .img-float-clear + p.diary-img-right + p {
margin-top: 0;
}
#workskin .img-float-clear {
clear: both;
}Basic diary entry
October 31st, 1998
Dear diary, Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Goodnight for now.
HTML
<div class="diary">
<p class="diary-date">Date here</p>
<div class="diary-content">
<p>First paragraph here.</p>
<hr>
<p>Another paragraph here.</p>
</div>
<p class="diary-signature">Signature here</p>
</div>Diary entry with image
→ Add an image to your entry:
- Find the
<p class="diary-img-left"><img width="40%" src="img-url-here"></p>tag, swap in your own URL and adjust the width to your liking. - A mirrored
diary-img-rightclass is also available if you'd rather float the image to the right. - To use a centered image:
<p align="center"><img src="img-url-here"></p>. Note that centered images are fixed at 136px in height to stay aligned with the ruled lines. If you adjust this value in the CSS, make sure it remains a multiple of 24px to keep the lines in sync.
Demo
October 31st, 1998

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.

Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
Goodnight for now.
HTML
<div class="diary">
<p class="diary-date">Date here</p>
<div class="diary-content">
<p class="diary-img-left">
<img width="40%" src="img-url-here">
</p>
<p>First paragraph here.</p>
<div class="img-float-clear"></div>
<p>Another paragraph here.</p>
</div>
<p class="diary-signature">Signature here</p>
</div>
b) Journal (tab view) ↑
A decorative cover panel and a sidebar of hoverable tabs that reveal your content.
The full code follows the demos (covers both standard and bigger variants).
Standard demo
My Private Diary
Strictly Confidential
Keep Out
Bigger demo
My Private Diary
Strictly Confidential
Keep Out
Full code
→ Mobile Compatibility: Note that the layout does not adapt perfectly to smaller screens. The content will overflow on mobile. However, the standard version remains significantly more readable on mobile screens than the .bigger modifier version.
→ Modifier: To switch to larger dimensions, add the class bigger alongside the main class (example: <div class="doc-diary bigger">).
→ How it works: To add a tab, copy the whole tab block (from <!-- TAB START --> to <!-- TAB END -->) and paste it right after the previous one. Since this can be a bit tricky at first, the available classes, adding images, customizing things, and how the code works more broadly are explained in detail at the end of this work.
HTML
<div class="doc-diary">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Subtitle</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START -->
<div class="tab">
<!-- TAB BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Label here.</p>
</div>
</div>
<!-- TAB BUTTON END -->
<!-- TAB CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">
<span class="accent">Tab 1:</span>
Tab title here.
</p>
<p class="tab-section">Section title here.</p>
<p class="img-left">
<img width="40%" src="img-url-here">
</p>
<p>Paragraph here.</p>
<div class="img-float-clear"></div>
<hr>
<p class="tab-section">Another section title here.</p>
<p>Another paragraph here.</p>
</div>
</div>
<!-- TAB CONTENT END -->
</div>
<!-- TAB END -->
</div>
</div>Show CSS
/* ------------------------------------------------------------
SCROLLBAR
------------------------------------------------------------ */
#workskin .doc-diary * {
scrollbar-color: #cfd5df transparent;
}
/* ------------------------------------------------------------
CONTAINER
Outer wrapper, cover and panels dimensions.
------------------------------------------------------------ */
#workskin .doc-diary {
width: 565px;
margin: auto;
position: relative;
overflow: hidden;
}
#workskin .doc-diary .doc-cover,
#workskin .doc-diary .tab-panel {
width: 375px;
}
#workskin .doc-diary,
#workskin .doc-diary .doc-cover,
#workskin .doc-diary .tab-panel {
height: 444px;
background-color: white;
box-sizing: border-box;
}
/* Padding */
#workskin .doc-diary .doc-cover,
#workskin .doc-diary .tab-panel {
padding-inline: 19px 0;
}
/* ------------------------------------------------------------
COVER
Decorative left panel with background image.
------------------------------------------------------------ */
#workskin .doc-diary .doc-cover {
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 0;
top: 0;
opacity: 0.9;
z-index: 1;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-cover-diary.jpg");
background-size: contain;
background-repeat: no-repeat;
filter: saturate(0.8) sepia(0.1);
}
/* ------------------------------------------------------------
COVER — DECORATIVE IMAGE
Icon or illustration displayed on the cover panel.
------------------------------------------------------------ */
#workskin .doc-diary .doc-img {
order: 2;
width: 170px;
height: 95px;
margin-top: 10%;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/diary-lock.png");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
filter: drop-shadow(0px 3px 5px rgba(0, 0, 0, 0.5)) contrast(1.1);
}
/* ------------------------------------------------------------
COVER — HEADLINE
Title and subtitle block displayed on the cover image.
------------------------------------------------------------ */
/* Headline */
#workskin .doc-diary .doc-headline {
order: 1;
margin-top: 41%;
padding-inline: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
#workskin .doc-diary .doc-headline p {
width: 190px;
margin: 0;
padding: 0;
font-family: "Lucida Handwriting", "Comic Sans MS", cursive;
text-align: center;
color: #0f0f3e;
}
#workskin .doc-diary .doc-headline p,
#workskin .doc-diary .doc-headline .doc-title-separator {
transform: rotate(-5deg);
padding-block: 1px;
}
/* Title */
#workskin .doc-diary .doc-headline p.doc-title {
padding-inline: 10px;
font-size: 18px;
line-height: 1;
}
/* Subtitle */
#workskin .doc-diary .doc-headline p.doc-subtitle {
padding-inline: 15px;
font-size: 15px;
line-height: 1;
}
/* ------------------------------------------------------------
SIDEBAR
Right column holding all tab buttons.
Acts as positioning context for all panels.
overflow: hidden clips panels at rest;
:has(.tab:hover) reveals them on hover.
------------------------------------------------------------ */
#workskin .doc-diary .sidebar {
position: absolute;
right: 0;
top: 0;
width: 190px;
height: 100%;
display: flex;
flex-direction: column;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
z-index: 10;
overflow: hidden;
}
#workskin .doc-diary .sidebar:has(.tab:hover) {
overflow: visible;
}
/* ------------------------------------------------------------
TAB
Individual tab item.
------------------------------------------------------------ */
#workskin .doc-diary .tab {
flex: 1;
overflow: hidden;
z-index: 10;
}
#workskin .doc-diary .tab:hover {
overflow: visible;
z-index: 20;
}
/* ------------------------------------------------------------
TAB — BUTTON
Visible area. Reveals the panel on hover.
------------------------------------------------------------ */
#workskin .doc-diary .tab-btn {
display: block;
width: 100%;
height: 100%;
border: ridge rgba(220, 210, 190, 0.8);
background-position: center center;
cursor: pointer;
transition: filter 300ms ease-in-out, opacity 300ms ease-in-out;
box-sizing: border-box;
position: relative;
z-index: 5;
opacity: 0.7;
}
#workskin .doc-diary .tab:hover .tab-btn {
opacity: 0.85;
filter: saturate(40%);
}
/* ------------------------------------------------------------
TAB BUTTON IMAGES
Default image shared by all tabs. Override per tab using
:nth-child(N) to assign a different image to each category.
Example:
#workskin .doc-diary .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
------------------------------------------------------------ */
#workskin .doc-diary .tab-btn {
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/collage.jpg");
background-position: 55% 60%;
background-size: 200%;
}
/* Per-tab overrides (uncomment and fill in URLs):
#workskin .doc-diary .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-diary .tab:nth-child(2) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-diary .tab:nth-child(3) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-diary .tab:nth-child(4) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-diary .tab:nth-child(5) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* ------------------------------------------------------------
TAB — LABEL
Text overlay at the bottom of each tab button.
------------------------------------------------------------ */
#workskin .doc-diary .tab-label {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 6;
box-sizing: border-box;
background-color: rgba(247, 242, 234, 0.88);
border-top: 1px solid rgba(170, 150, 120, 0.35);
box-shadow: 0 -1px 5px #373737;
border-radius: 35% 10%;
}
/* Label text */
#workskin .doc-diary .tab-label p {
margin-block: 7px;
font-family: "Lucida Handwriting", "Comic Sans MS", cursive;
font-size: 12px;
font-weight: bold;
text-align: center;
line-height: 1.3;
letter-spacing: 0.02em;
color: #0f0f3e;
}
#workskin .doc-diary .tab-label .red {
color: #ff0000;
}
/* ------------------------------------------------------------
TAB — PANEL
Scrollable content panel revealed on tab hover.
Positioned against .sidebar (its stacking context).
top: 0 keeps it flush with the container top regardless
of which tab is hovered.
------------------------------------------------------------ */
#workskin .doc-diary .tab-panel {
position: absolute;
top: 0;
right: 100%;
z-index: 19;
background-clip: content-box;
overflow: auto;
display: none;
}
#workskin .doc-diary .tab:hover .tab-panel {
display: block;
}
/* ------------------------------------------------------------
TAB — PANEL CONTENT
Inner content area.
------------------------------------------------------------ */
#workskin .doc-diary .tab-content {
width: 100%;
padding: 25px 14px;
padding-left: 40px;
box-sizing: border-box;
position: relative;
background-image: repeating-linear-gradient(to bottom, #ffffff 0px, #ffffff 21px, #00b0d7 21px, #00b0d7 22px);
background-attachment: scroll;
}
#workskin .doc-diary .tab-content::before {
content: '';
display: block;
position: absolute;
z-index: 1;
top: 0;
left: 30px;
height: 100%;
width: 1px;
background: #db4034;
}
#workskin .doc-diary .tab-content p {
font-family: "Lucida Handwriting", "Comic Sans MS", cursive;
color: #0f0f3e;
font-size: 13px;
line-height: 22px;
margin-block: 22px;
}
#workskin .doc-diary .tab-content p.tab-title {
margin-top: 0;
font-size: 17px;
}
#workskin .doc-diary .tab-content p.tab-section {
font-size: 15px;
color: #00807c;
}
/* Images */
#workskin .doc-diary .tab-content > p[align="center"] img {
width: auto;
height: 136px;
}
#workskin .doc-diary .tab-content > p.img-left img {
margin-right: 10px;
float: left;
}
#workskin .doc-diary .tab-content > p.img-right img {
margin-left: 10px;
float: right;
}
#workskin .doc-diary .tab-content .img-float-clear + p,
#workskin .doc-diary .tab-content .img-float-clear + p.img-left + p,
#workskin .doc-diary .tab-content .img-float-clear + p.img-right + p {
margin-top: 0;
}
#workskin .doc-diary .tab-content .img-float-clear {
clear: both;
}
/* Accent colors */
#workskin .doc-diary .accent {
color: #bd0000; /* red */
}
/* <hr> separator */
#workskin .doc-diary .doc-headline .doc-title-separator,
#workskin .doc-diary .tab-content hr {
border: 0;
border-top: 2px solid #ff6ae0;
width: 100%;
position: relative;
overflow: visible;
}
#workskin .doc-diary .doc-headline .doc-title-separator {
margin: 5px auto;
}
#workskin .doc-diary .tab-content hr {
margin-inline: auto;
margin-top: -5px;
margin-bottom: 25px;
}
/* ------------------------------------------------------------
BIGGER MODIFIER
Add .bigger to switch to larger dimensions.
All overrides for .bigger are grouped here.
Example: <div class="doc-diary bigger">
------------------------------------------------------------ */
/* Container — Outer wrapper, cover and panels dimensions. */
#workskin .bigger.doc-diary {
width: 765px;
}
#workskin .bigger.doc-diary,
#workskin .bigger.doc-diary .doc-cover,
#workskin .bigger.doc-diary .tab-panel {
height: 682px;
}
#workskin .bigger.doc-diary .doc-cover,
#workskin .bigger.doc-diary .tab-panel {
width: 575px;
padding-inline: 30px 0;
}
/* Cover image and margin */
#workskin .bigger.doc-diary .doc-img {
width: 200px;
height: 125px;
margin-top: 18%;
}
/* Headline */
#workskin .bigger.doc-diary .doc-headline {
margin-top: 43%;
}
#workskin .bigger.doc-diary .doc-headline p {
width: 315px;
}
#workskin .bigger.doc-diary .doc-headline p,
#workskin .bigger.doc-diary .doc-headline .doc-title-separator {
padding-block: 2px;
}
/* Title */
#workskin .bigger.doc-diary .doc-headline p.doc-title {
font-size: 22px;
}
/* Subtitle */
#workskin .bigger.doc-diary .doc-headline p.doc-subtitle {
font-size: 17px;
}
/* Tab labels */
#workskin .bigger.doc-diary .tab-label p {
font-size: 13px;
}
/* Tab button images — add per-tab overrides here, one entry per tab:
.tab:nth-child(1) for the first button, .tab:nth-child(2) for the second button, and so on.
Example:
#workskin .bigger.doc-diary .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* Tab content — Background */
#workskin .bigger.doc-diary .tab-content {
padding: 37px 14px;
padding-left: 60px;
background-image: repeating-linear-gradient(to bottom, #ffffff 0px, #ffffff 29px, #00b0d7 29px, #00b0d7 30px);
}
#workskin .bigger.doc-diary .tab-content::before {
left: 50px;
}
/* Tab content — Font size */
#workskin .bigger.doc-diary .tab-content p {
font-size: 14px;
line-height: 30px;
margin-block: 30px;
}
#workskin .bigger.doc-diary .tab-content p.tab-title {
margin-top: 0;
font-size: 18px;
}
#workskin .bigger.doc-diary .tab-content p.tab-section {
font-size: 16px;
}
/* <hr> separator */
#workskin .bigger.doc-diary .tab-content hr {
margin-inline: auto;
margin-top: -9px;
margin-bottom: 37px;
}
6. FILE/FOLDERS ↑
a) Single file ↑
A single classified file page, styled like a typewritten dossier.
→ The page expands to fit however much content you add (no scrollbar).
Full CSS (includes all the following demos — HTML follows each demo)
Show CSS
/* ============================================================
FILE — SINGLE PAGE
============================================================ */
#workskin .file {
max-width: 38em;
margin: auto;
padding: 2em 2.5em;
box-sizing: border-box;
position: relative;
color: black;
font-family: "Courier New", Courier, monospace;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
background-color: rgb(247 242 234);
box-shadow: 0 0 10px #bcbcbc;
}
#workskin .file p {
margin: 15px auto;
}
#workskin .file-title {
text-align: center;
font-weight: bold;
text-transform: uppercase;
letter-spacing: 1px;
font-variant: small-caps;
font-size: 1.3em;
padding-block: 15px;
border-block: 2px dashed #4a3e3d;
}
#workskin .file-content p {
font-size: 14px;
line-height: 18px;
}
#workskin .file-content p:last-of-type {
margin-bottom: 0;
}
#workskin .file-stamp {
display: inline-block;
margin-top: 10px;
padding: 4px 16px;
border: 3px solid #bd0000;
border-radius: 4px;
color: #bd0000;
font-weight: bold;
text-transform: uppercase;
letter-spacing: 2px;
transform: rotate(-6deg);
opacity: 0.85;
}
#workskin .file .accent {
color: #bd0000;
}
#workskin .file-content hr {
border: 0;
border-top: 2px dashed #4a3e3d;
width: 90%;
margin: 30px auto;
position: relative;
overflow: visible;
}
/* ============================================================
FILE — IMAGES
No need to add #workskin .img-float-clear again if already included via another component's image css
============================================================ */
#workskin .file-content > p:has(img) {
filter: grayscale(0.8);
}
#workskin .file-content > p.file-img-left img {
margin-right: 10px;
float: left;
}
#workskin .file-content > p.file-img-right img {
margin-left: 10px;
float: right;
}
#workskin .file-content .img-float-clear + p,
#workskin .file-content .img-float-clear + p.file-img-left + p,
#workskin .file-content .img-float-clear + p.file-img-right + p {
margin-top: 0;
}
#workskin .img-float-clear {
clear: both;
}Basic file
Classified
Case File #047
Subject: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
HTML
<div class="file">
<p class="file-stamp">Classified</p>
<p class="file-title">Title of the File</p>
<div class="file-content">
<p>First paragraph here.</p>
<hr>
<p>Another paragraph here.</p>
</div>
</div>File with image
→ Add an image to your file:
- Find the
<p class="file-img-left"><img width="40%" src="img-url-here"></p>tag, swap in your own URL and adjust the width to your liking. - A mirrored
file-img-rightclass is also available if you'd rather float the image to the right. - To use a centered image:
<p align="center"><img width="80%" src="img-url-here"></p>. Adjust the width however you like.
Demo
Classified
Case File #047

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam ac leo in elit tristique porta et nec tortor. Maecenas maximus vel lectus in pharetra. Nam id justo vestibulum, faucibus eros vitae, mollis neque. Aliquam lacinia eros libero, quis rhoncus justo commodo at. Phasellus porta finibus nisl ut dictum. Pellentesque consectetur ultricies nunc. Proin id volutpat eros. Donec volutpat risus ac mauris gravida congue. Aenean cursus ligula et erat fringilla, at ornare arcu dignissim.
Aenean ut risus tellus. Morbi ac neque quis lorem tincidunt ultrices nec id magna. Integer tellus diam, vehicula eget augue vel, imperdiet consequat lacus. Donec porttitor sit amet ipsum fringilla volutpat. Morbi quam tellus, ornare et ante a, vehicula blandit nisi. Fusce malesuada, felis eu maximus viverra, felis nibh congue leo, eu consequat eros lorem sed lectus. Sed laoreet condimentum nunc, ac elementum turpis molestie vel. Aliquam posuere magna a justo pharetra vestibulum a id eros. Morbi fringilla nulla nulla, ac convallis risus finibus sed.
HTML
<div class="file">
<p class="file-stamp">Classified</p>
<p class="file-title">Title of the File</p>
<div class="file-content">
<p class="file-img-left">
<img width="40%" src="img-url-here">
</p>
<p>First paragraph here.</p>
<div class="img-float-clear"></div>
<p>Another paragraph here.</p>
</div>
</div>
b) Folders (tab view) ↑
A decorative cover panel and a sidebar of hoverable tabs that reveal your content.
The full code follows the demos (covers both standard and bigger variants).
Standard demo
Central Archive: Section 9
Classified dossiers and sensitive active operations
Bigger demo
Central Archive: Section 9
Classified dossiers and sensitive active operations
Full code
→ Mobile Compatibility: Note that the layout does not adapt perfectly to smaller screens. The content will overflow on mobile. However, the standard version remains significantly more readable on mobile screens than the .bigger modifier version.
→ Modifier: To switch to larger dimensions, add the class bigger alongside the main class (example: <div class="doc-folders bigger">).
→ How it works: To add a tab, copy the whole tab block (from <!-- TAB START --> to <!-- TAB END -->) and paste it right after the previous one. Since this can be a bit tricky at first, the available classes, adding images, customizing things, and how the code works more broadly are explained in detail at the end of this work.
HTML
<div class="doc-folders">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Subtitle</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START -->
<div class="tab">
<!-- TAB BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Label here.</p>
</div>
</div>
<!-- TAB BUTTON END -->
<!-- TAB CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">
<span class="accent">Tab 1:</span>
Tab title here.
</p>
<p class="tab-section">Section title here.</p>
<p class="img-left">
<img width="40%" src="img-url-here">
</p>
<p>Paragraph here.</p>
<div class="img-float-clear"></div>
<hr>
<p class="tab-section">Another section title here.</p>
<p>Another paragraph here.</p>
</div>
</div>
<!-- TAB CONTENT END -->
</div>
<!-- TAB END -->
</div>
</div>Show CSS
/* ------------------------------------------------------------
SCROLLBAR
------------------------------------------------------------ */
#workskin .doc-folders * {
scrollbar-color: #776d64 transparent;
}
/* ------------------------------------------------------------
CONTAINER
Outer wrapper, cover and panels dimensions.
------------------------------------------------------------ */
#workskin .doc-folders {
width: 565px;
margin: auto;
position: relative;
overflow: hidden;
}
#workskin .doc-folders .doc-cover,
#workskin .doc-folders .tab-panel {
width: 375px;
}
#workskin .doc-folders,
#workskin .doc-folders .doc-cover,
#workskin .doc-folders .tab-panel {
height: 445px;
background-color: rgb(247 242 234);
box-sizing: border-box;
}
/* Padding & transparent border */
#workskin .doc-folders .doc-cover {
padding-inline: 19px;
}
#workskin .doc-folders .tab-panel {
border-inline: 19px solid transparent;
}
/* ------------------------------------------------------------
COVER
Decorative left panel with background image.
------------------------------------------------------------ */
#workskin .doc-folders .doc-cover {
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 0;
top: 0;
opacity: 0.9;
z-index: 1;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/doc-cover-folders.jpg");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
}
/* ------------------------------------------------------------
COVER — DECORATIVE IMAGE
Icon or illustration displayed on the cover panel.
------------------------------------------------------------ */
#workskin .doc-folders .doc-img {
width: 170px;
height: 95px;
margin-block: 14%;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/confidential.png");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
transform: rotate(10deg);
filter: saturate(0.7);
}
/* ------------------------------------------------------------
COVER — HEADLINE
Title and subtitle block displayed on the cover image.
------------------------------------------------------------ */
/* Headline */
#workskin .doc-folders .doc-headline {
width: 100%;
padding-inline: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
box-sizing: border-box;
}
#workskin .doc-folders .doc-headline p {
margin: 0;
font-family: "Courier New", Courier, monospace;
font-weight: bold;
text-align: center;
color: black;
}
/* Title */
#workskin .doc-folders .doc-headline p.doc-title {
padding-bottom: 15px;
padding-inline: 10px;
font-size: 23px;
font-variant: small-caps;
line-height: 1;
}
/* Subtitle */
#workskin .doc-folders .doc-headline p.doc-subtitle {
padding-top: 15px;
padding-inline: 15px;
font-size: 15px;
line-height: 1;
}
/* ------------------------------------------------------------
SIDEBAR
Right column holding all tab buttons.
Acts as positioning context for all panels.
overflow: hidden clips panels at rest;
:has(.tab:hover) reveals them on hover.
------------------------------------------------------------ */
#workskin .doc-folders .sidebar {
position: absolute;
right: 0;
top: 0;
width: 190px;
height: 100%;
display: flex;
flex-direction: column;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/old-parchment-texture.jpg");
z-index: 10;
overflow: hidden;
}
#workskin .doc-folders .sidebar:has(.tab:hover) {
overflow: visible;
}
/* ------------------------------------------------------------
TAB
Individual tab item.
------------------------------------------------------------ */
#workskin .doc-folders .tab {
flex: 1;
overflow: hidden;
z-index: 10;
}
#workskin .doc-folders .tab:hover {
overflow: visible;
z-index: 20;
}
/* ------------------------------------------------------------
TAB — BUTTON
Visible area. Reveals the panel on hover.
------------------------------------------------------------ */
#workskin .doc-folders .tab-btn {
display: block;
width: 100%;
height: 100%;
border: ridge rgba(220, 210, 190, 0.8);
background-position: center center;
cursor: pointer;
transition: filter 300ms ease-in-out, opacity 300ms ease-in-out;
box-sizing: border-box;
position: relative;
z-index: 5;
opacity: 0.7;
filter: brightness(1.3) saturate(50%);
}
#workskin .doc-folders .tab:hover .tab-btn {
opacity: 0.85;
filter: brightness(1) saturate(40%);
}
/* ------------------------------------------------------------
TAB BUTTON IMAGES
Default image shared by all tabs. Override per tab using
:nth-child(N) to assign a different image to each category.
Example:
#workskin .doc-folders .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
------------------------------------------------------------ */
#workskin .doc-folders .tab-btn {
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/files.jpg");
background-position: 75% center;
background-size: 200%;
}
/* Per-tab overrides (uncomment and fill in URLs):
#workskin .doc-folders .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folders .tab:nth-child(2) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folders .tab:nth-child(3) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folders .tab:nth-child(4) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
#workskin .doc-folders .tab:nth-child(5) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* ------------------------------------------------------------
TAB — LABEL
Text overlay at the bottom of each tab button.
------------------------------------------------------------ */
#workskin .doc-folders .tab-label {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
z-index: 6;
box-sizing: border-box;
background-color: rgba(247, 242, 234, 0.88);
border-top: 1px solid rgba(170, 150, 120, 0.35);
box-shadow: 0 -1px 5px #373737;
border-radius: 30px 30px 0 0;
}
/* Label text */
#workskin .doc-folders .tab-label p {
margin-block: 7px;
font-family: monospace, "Courier New", Courier;
font-size: 12px;
line-height: 1.3;
font-weight: bold;
text-align: center;
letter-spacing: 0.02em;
text-transform: uppercase;
color: black;
}
#workskin .doc-folders .tab-label .red {
color: #ff0000;
}
/* ------------------------------------------------------------
TAB — PANEL
Scrollable content panel revealed on tab hover.
Positioned against .sidebar (its stacking context).
top: 0 keeps it flush with the container top regardless
of which tab is hovered.
------------------------------------------------------------ */
#workskin .doc-folders .tab-panel {
position: absolute;
top: 0;
right: 100%;
z-index: 19;
background-image: url("https://raw.githubusercontent.com/lostquill/ao3-the-scriptorium/main/assets/parchment-texture.jpg");
background-size: 100%;
background-repeat: repeat;
background-clip: content-box;
overflow: auto;
display: none;
}
#workskin .doc-folders .tab:hover .tab-panel {
display: block;
}
/* ------------------------------------------------------------
TAB — PANEL CONTENT
Inner content area.
------------------------------------------------------------ */
#workskin .doc-folders .tab-content {
width: 100%;
padding: 12px 14px;
box-sizing: border-box;
position: relative;
}
#workskin .doc-folders .tab-content p {
font-family: "Courier New", Courier, monospace;
color: black;
font-size: 13px;
line-height: 18px;
}
#workskin .doc-folders .tab-content p.tab-title {
text-align: center;
font-size: 17px;
padding-block: 20px;
border-block: 2px dashed #4a3e3d;
}
#workskin .doc-folders .tab-content p.tab-section {
font-size: 15px;
padding-bottom: 4px;
border-bottom: 1px dashed #868686;
}
/* Images */
#workskin .doc-folders .tab-content > p:has(img) {
filter: grayscale(0.8);
}
#workskin .doc-folders .tab-content > p.img-left img {
margin-right: 10px;
float: left;
}
#workskin .doc-folders .tab-content > p.img-right img {
margin-left: 10px;
float: right;
}
#workskin .doc-folders .tab-content .img-float-clear + p,
#workskin .doc-folders .tab-content .img-float-clear + p.img-left + p,
#workskin .doc-folders .tab-content .img-float-clear + p.img-right + p {
margin-top: 0;
}
#workskin .doc-folders .tab-content .img-float-clear {
clear: both;
}
/* Accent colors */
#workskin .doc-folders .accent {
color: #bd0000; /* red */
}
/* <hr> separator */
#workskin .doc-folders .doc-headline .doc-title-separator,
#workskin .doc-folders .tab-content hr {
border: 0;
border-top: 2px dashed #4a3e3d;
width: 90%;
position: relative;
overflow: visible;
}
#workskin .doc-folders .doc-headline .doc-title-separator {
margin: 20px auto;
}
#workskin .doc-folders .tab-content hr {
margin: 35px auto;
}
/* ------------------------------------------------------------
BIGGER MODIFIER
Add .bigger to switch to larger dimensions.
All overrides for .bigger are grouped here.
Example: <div class="doc-folders bigger">
------------------------------------------------------------ */
/* Container — Outer wrapper, cover and panels dimensions. */
#workskin .bigger.doc-folders {
width: 765px;
}
#workskin .bigger.doc-folders,
#workskin .bigger.doc-folders .doc-cover,
#workskin .bigger.doc-folders .tab-panel {
height: 682px;
}
#workskin .bigger.doc-folders .doc-cover,
#workskin .bigger.doc-folders .tab-panel {
width: 575px;
}
#workskin .bigger.doc-folders .doc-cover {
padding-inline: 28px;
}
#workskin .bigger.doc-folders .tab-panel {
border-inline: 28px solid transparent;
}
/* Cover image and margin */
#workskin .bigger.doc-folders .doc-img {
width: 200px;
height: 125px;
margin-block: 16%;
}
/* Headline */
#workskin .bigger.doc-folders .doc-headline p.doc-title {
font-size: 30px;
}
#workskin .bigger.doc-folders .doc-headline p.doc-subtitle {
font-size: 17px;
}
/* Tab labels */
#workskin .bigger.doc-folders .tab-label p {
font-size: 13px;
}
/* Tab button images — add per-tab overrides here, one entry per tab:
.tab:nth-child(1) for the first button, .tab:nth-child(2) for the second button, and so on.
Example:
#workskin .bigger.doc-folders .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
} */
/* Tab content — Font size */
#workskin .bigger.doc-folders .tab-content p {
font-size: 14px;
line-height: 22px;
}
#workskin .bigger.doc-folders .tab-content p.tab-title {
font-size: 18px;
}
#workskin .bigger.doc-folders .tab-content p.tab-section {
font-size: 16px;
}
TAB VIEW: HOW IT WORKS ↑
If you're finding the tab structure confusing, this section might help!
Adding tabs
Every hover tab-view component above (parchment stack, codex, book, gazette, diary, folders) is built the same way: each tab is one self-contained tab block, running from <!-- TAB START --> to <!-- TAB END -->, which bundles the tab's button together with its content panel. To add a tab, copy that whole block and paste it right after the previous one, repeating the process for as many tabs as you need (well, not too many or it’ll get cluttered and a pain to navigate).
If your tabs end up blending into one another, or some don't show up at all, it's almost always because a full structure (a whole tab-panel, tab-content, or even tab block) got duplicated somewhere it shouldn't have. Double-check that you only have as many tab blocks as you have tabs, and that every opening tag has its matching closing tag.
Tab view components are prone to structural errors like these. If you haven't already, see the How to Use section, where I explain how to set up CodePen (instead of using AO3's editor) to preserve your code's comments and indentation, and to get an accurate preview. It'll save you a lot of headaches here.
The HTML shown for each component above only included a single tab, for the sake of clarity. To make the copy-paste process more obvious, here's a fuller example (built with the Folders component) with three tabs placed one after another:
HTML
<div class="doc-folders">
<!-- DOC COVER START -->
<div class="doc-cover">
<div class="doc-img"></div>
<div class="doc-headline">
<p class="doc-title">Insert your title</p>
<div class="doc-title-separator"></div>
<p class="doc-subtitle">Insert text here</p>
</div>
</div>
<!-- DOC COVER END -->
<div class="sidebar">
<!-- TAB START = THIS IS WHERE TAB 1 STARTS, COPY FROM THIS POINT TO CREATE THE NEXT TABS -->
<div class="tab">
<!-- TAB 1 BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Insert label here.</p>
</div>
</div>
<!-- TAB 1 BUTTON END -->
<!-- TAB 1 CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">Your tab title here</p>
<p>First paragraph.</p>
<p>Second paragraph.</p>
<p>Third paragraph and so on...</p>
</div>
</div>
<!-- TAB 1 CONTENT END -->
</div>
<!-- TAB END = THIS IS WHERE TAB 1 ENDS, COPY UP TO HERE FOR EACH NEW TAB -->
<!-- TAB START = THIS IS WHERE TAB 2 STARTS -->
<div class="tab">
<!-- TAB 2 BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Insert label here.</p>
</div>
</div>
<!-- TAB 2 BUTTON END -->
<!-- TAB 2 CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">Your tab title here</p>
<p>First paragraph.</p>
<p>Second paragraph.</p>
<p>Third paragraph and so on...</p>
</div>
</div>
<!-- TAB 2 CONTENT END -->
</div>
<!-- TAB END = THIS IS WHERE TAB 2 ENDS -->
<!-- TAB START = THIS IS WHERE TAB 3 STARTS -->
<div class="tab">
<!-- TAB 3 BUTTON START -->
<div class="tab-btn">
<div class="tab-label">
<p>Insert label here.</p>
</div>
</div>
<!-- TAB 3 BUTTON END -->
<!-- TAB 3 CONTENT START -->
<div class="tab-panel">
<div class="tab-content">
<p class="tab-title">Your tab title here</p>
<p>First paragraph.</p>
<p>Second paragraph.</p>
<p>Third paragraph and so on...</p>
</div>
</div>
<!-- TAB 3 CONTENT END -->
</div>
<!-- TAB END = THIS IS WHERE TAB 3 ENDS -->
<!-- THIS IS WHERE YOU PASTE A FOURTH TAB (AND MORE) IF NEEDED -->
</div>
</div>The only class name that changes from one component to another is the outer wrapper (doc-folders here, since this example is built with the Folders component). Swap it for whichever component you're actually using (doc-folio, doc-codex, doc-book, doc-newspaper, doc-diary...). Everything else (doc-cover and everything inside it, sidebar, tab, tab-btn, tab-panel, etc...) is shared across every component and stays exactly the same.
Wrapper class reference
doc-folio— Parchment (Stack)doc-codex— Codex (Manuscript)doc-book— Book (Volume)doc-newspaper— Newspaper (Gazette)doc-diary— Diary (Journal)doc-folders— File/folders (Folders)
Modifier
Adding the class bigger alongside the main component class switches to the larger dimensions shown in each "Bigger demo" above (example: <div class="doc-folders bigger">).
If you're editing the CSS, keep in mind that the rules under the BIGGER MODIFIER section at the end of the file override the normal selectors for anything specific to that larger version. If a property is duplicated there, you'll need to edit it there instead (editing the normal selector won't have any effect once the bigger class is active). For example, to change the title's font size you'd need to edit it in #workskin .bigger.doc-folders .doc-headline p.doc-title, not in #workskin .doc-folders .doc-headline p.doc-title, since the existing bigger-specific rule overrides it.
Breaking down the structure
<!-- DOC COVER START --> — the decorative cover, with an image, a title, and a subtitle, as follows:
doc-img: an image/icondoc-headline: wrapper for the title block, which itself contains:doc-title: the main titledoc-title-separator: the decorative divider between title and subtitledoc-subtitle: the subtitle
This whole block appears once, and isn't repeated for each tab.
Now we enter the tab block itself.
<!-- TAB BUTTON START --> — the hoverable button in the sidebar:
- the button itself (
tab-btn) displays a background image, which you can set or change in the CSS. Note that having fewer tabs will cause the button images to distort or look misaligned; in those cases, you may need to adjust the background properties (position, size...) in the CSS to keep things looking the way you want. You can also assign a unique background image to each button instead of sharing one across all of them, the CSS for this is already commented out in theTAB BUTTON IMAGESsection of each component, ready for you to uncomment and fill in. For example, in the Folders component, to give the first tab its own image you'd uncomment and edit:
#workskin .doc-folders .tab:nth-child(1) .tab-btn {
background-image: url("img-url-here");
background-position: center center;
background-size: cover;
}
and repeat with:nth-child(2),:nth-child(3), and so on for the other tabs. If you're also using the.biggermodifier, a separate commented-out section exists for that too, using the selector#workskin .bigger.doc-folders .tab:nth-child(1) .tab-btninstead, but it's only really needed if you're displaying both sizes of the same component on the same page and want a different image for each. Odds are that won't come up, so you can safely stick to the regular selector. You might point out that I could just remove the bigger section for these overrides at that point, but... well I'm tired and you never know. =) tab-label: wrapper for the text shown on the button- the label text itself, inside a single
<p>
<!-- TAB CONTENT START --> — the panel revealed on hover. tab-panel is the outer scroll container; tab-content is the inner wrapper where you actually write your content. Inside it, you can use:
tab-title: the panel's title paragraphtab-section: a smaller section heading within the panel, used to break the content into segments- plain
<p>paragraphs for body text. In the codex and book tab view components specifically, a decorative drop cap is applied automatically to the first paragraph (provided it isn't a title or section header); you can also apply it manually to any paragraph in these two components by adding the classinitial. Note that this isn't automatic in the single-page versions of these components: the single codex page still supportsinitialmanually, but the single book page (back cover / inner page) doesn't support a drop cap at all img-left/img-righton a paragraph to float an image left or right, followed by animg-float-cleardiv to clear the float before the next paragraph. This clear is important: without it, if the image is taller than the text sitting next to it, the image will overflow past that text and spill onto whatever comes after it instead of stopping cleanly.
For example, float the image, add your text, then clear the float before moving on:
<p class="img-left"><img width="40%" src="img-url-here"></p>
<p>Your paragraph text here.</p>
<div class="img-float-clear"></div>
Swap in your own URL and adjust the width to your liking;img-rightworks the same way, mirrored. In the parchment stack, diary, and folders components, body text isn't justified by default; if you useimg-rightthere and want a cleaner look, addtext-align: justify;to that component's.tab-content prule in the CSS (for example#workskin .doc-folio .tab-content p).
To center an image instead, usealign="center"directly on the paragraph rather than a class:<p align="center"><img width="80%" src="img-url-here"></p>, adjusting the width as you like. One exception: in the diary, centered images are fixed at 136px in height to stay aligned with the ruled lines; if you adjust this value in the CSS, keep it a multiple of 22px to stay in sync<hr>to add a divider between sections<span class="accent">: wraps any bit of text in a highlight color, anywhere in the panel, for example:<span class="accent">Something smart</span>. The actual color is set per component in the CSS, so it'll differ depending on which one you're using
Each tab block (button and panel together) is what you duplicate to add a new tab, as explained above.
Of course, feel free to customize the CSS as you like, that's your baby now.
And that's it for now. Enjoy!
