/* 1. Variables */ :root { --color-white: #fff; --color-lighter-gray: #f6f6f6; --color-light-gray: #e6e6e6; --color-mid-gray: #ccc; --color-dark-gray: #444; --color-darker-gray: #15171a; --color-black: #000; --color-primary-text: var(--color-darker-gray); --color-secondary-text: rgba(0, 0, 0, 0.4); --color-border: rgba(0, 0, 0, 0.08); --font-sans: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif; --font-serif: EB Garamond, Georgia, Times, serif; --font-slab: Roboto Slab; --font-mono: Menlo, Courier, monospace; --container-gap: clamp(24px, 1.7032rem + 1.9355vw, 48px); --grid-gap: 40px; } :root.has-light-text { --color-lighter-gray: rgba(0, 0, 0, 0.1); --color-darker-gray: #fff; --color-secondary-text: rgba(255, 255, 255, 0.64); --color-border: rgba(255, 255, 255, 0.2); } /* 2. Resets */ *, *::before, *::after { box-sizing: border-box; } * { margin: 0; } html { font-size: 62.5%; } body { line-height: 1.6; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } img, picture, video, canvas, svg { display: block; height: auto; max-width: 100%; } iframe { display: block; } input, button, textarea, select { font: inherit; } p, h1, h2, h3, h4, h5, h6 { overflow-wrap: break-word; } h1, h2, h3, h4, h5, h6 { line-height: 1.2; } /* 3. Globals */ body { font-family: var(--font-sans); font-size: 1.6rem; background-color: var(--background-color); color: var(--color-primary-text); } a { color: var(--color-darker-gray); text-decoration: none; } a:hover { opacity: 0.8; } .gh-button { display: inline-flex; gap: 0.4em; align-items: center; justify-content: center; padding: 0.75em 1.15em; font-size: 1.6rem; font-weight: 600; line-height: 1; color: var(--color-white); letter-spacing: inherit; cursor: pointer; background-color: var(--ghost-accent-color); border: 0; border-radius: 100px; } .gh-button:hover { opacity: 0.95; } .gh-icon-button { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 0; color: var(--color-darker-gray); cursor: pointer; background-color: transparent; border: 0; outline: none; } .gh-icon-button:hover svg { opacity: 0.8; } .gh-icon-button svg { width: 20px; height: 20px; } /* 4. Layout */ .gh-viewport { position: relative; display: flex; flex-direction: column; min-height: 100vh; } .gh-content { flex-grow: 1; } .gh-outer { padding: 0 max(4vmin, 20px); } .gh-inner { margin: 0 auto; max-width: 1280px; width: 100%; } /* Typography */ .has-sans-title [data-title] { font-family: var(--font-sans); } .has-serif-title [data-title] { font-family: var(--font-serif); } .has-slab-title [data-title] { font-family: var(--font-slab); } .has-sans-body [data-body] { font-family: var(--font-sans); } .has-serif-body [data-body] { font-family: Georgia; } /* 5. Navigation */ .gh-navigation { height: 100px; font-size: 1.5rem; font-weight: 500; color: var(--color-darker-gray); } .gh-navigation :is(.gh-navigation-logo, a:not(.gh-button), .gh-icon-button) { color: inherit; } .gh-navigation-inner { display: grid; grid-auto-flow: row dense; column-gap: 24px; align-items: center; height: 100%; } .gh-navigation-brand { line-height: 1; } .gh-navigation-logo { position: relative; font-size: 2.6rem; font-weight: 700; letter-spacing: -0.015em; white-space: nowrap; } .gh-navigation-logo img { max-height: 40px; } .gh-navigation-menu { display: flex; gap: 24px; align-items: center; } .gh-navigation .nav { display: inline-flex; gap: 24px; align-items: center; padding: 0; margin: 0; white-space: nowrap; list-style: none; } .gh-navigation .gh-more-toggle { position: relative; margin: 0 -6px; font-size: inherit; text-transform: inherit; } .gh-navigation .gh-more-toggle svg { width: 24px; height: 24px; } .gh-navigation-actions { display: flex; gap: 24px; align-items: center; justify-content: flex-end; } .gh-navigation-members { display: flex; gap: 20px; align-items: center; white-space: nowrap; } .gh-navigation-members .gh-button { font-size: inherit; font-weight: 600; } .gh-search { margin-right: -6px; margin-left: -6px; } .gh-navigation-brand .gh-search { margin-right: 2px; } @media (max-width: 767px) { .gh-navigation-members { flex-direction: column-reverse; gap: 16px; width: 100%; } .gh-navigation-actions .gh-search { display: none; } } @media (min-width: 768px) { .gh-navigation-brand .gh-search { display: none; } .gh-navigation:not(.is-dropdown-loaded) .gh-navigation-menu .nav > li { opacity: 0; } } /* 5.1. Accent color */ .gh-navigation.has-accent-color { background-color: var(--ghost-accent-color); color: #fff; } .gh-navigation.has-accent-color .gh-button { background-color: #fff; color: #15171a; } /* 5.1. Navigation variants */ /* ====================================================================== LOGO Home About Collection Author Portal Login Subscribe ====================================================================== */ .is-left-logo .gh-navigation-inner { grid-template-columns: auto 1fr auto; } @media (min-width: 992px) { .is-left-logo .gh-navigation-menu { margin-right: 64px; margin-left: 16px; } } /* ====================================================================== Home About Collection LOGO Login Subscribe ====================================================================== */ .is-middle-logo .gh-navigation-inner { grid-template-columns: 1fr auto 1fr; } .is-middle-logo .gh-navigation-brand { grid-column-start: 2; } .is-middle-logo .gh-navigation-actions { gap: 28px; } @media (min-width: 992px) { .is-middle-logo .gh-navigation-menu { margin-right: 64px; } } /* ====================================================================== Search LOGO Login Subscribe Home About Collection Author Portal ====================================================================== */ .is-stacked.gh-navigation { position: relative; height: auto; } .is-stacked .gh-navigation-inner { grid-template-columns: 1fr auto 1fr; } .is-stacked .gh-navigation-brand { display: flex; grid-row-start: 1; grid-column-start: 2; min-height: 80px; } @media (min-width: 992px) { .is-stacked .gh-navigation-inner { padding: 0; } .is-stacked .gh-navigation-brand { display: flex; align-items: center; height: 80px; } .is-stacked .gh-navigation-menu { grid-row-start: 2; grid-column: 1 / 4; justify-content: center; height: 56px; margin: 0 48px; } .is-stacked .gh-navigation-menu::before, .is-stacked .gh-navigation-menu::after { position: absolute; top: 80px; left: 0; width: 100%; height: 1px; content: ""; background-color: var(--color-border); } .is-stacked .gh-navigation-menu::after { top: 136px; } .is-stacked .gh-navigation-actions { grid-row-start: 1; grid-column: 1 / 4; justify-content: space-between; } } /* 5.2. Dropdown menu */ .gh-dropdown { position: absolute; top: 100%; right: -16px; z-index: 90; width: 200px; padding: 12px 0; margin-top: 24px; text-align: left; visibility: hidden; background-color: #fff; border-radius: 5px; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04), 0 7px 20px -5px rgba(0, 0, 0, 0.15); opacity: 0; transition: opacity 0.3s, transform 0.2s; transform: translate3d(0, 6px, 0); } .is-middle-logo .gh-dropdown { right: auto; left: -24px; } .is-dropdown-mega .gh-dropdown { display: grid; grid-template-columns: 1fr 1fr; grid-auto-flow: column; column-gap: 40px; width: auto; padding: 20px 32px; } .is-dropdown-open .gh-dropdown { visibility: visible; opacity: 1; transform: translateY(0); } .gh-dropdown li a { display: block; padding: 6px 20px; color: #15171a !important; } .is-dropdown-mega .gh-dropdown li a { padding: 8px 0; } /* 5.3. Burger icon */ .gh-burger { display: flex; justify-content: center; align-items: center; position: relative; display: none; margin-right: -7px; } .gh-burger svg { width: 24px; height: 24px; } .gh-burger svg:last-child { display: none; } .is-open .gh-burger svg:first-child { display: none; } .is-open .gh-burger svg:last-child { display: block; } @media (max-width: 767px) { .gh-burger { display: flex; } } /* 5.4. Mobile menu */ @media (max-width: 767px) { #gh-navigation { height: 64px; } #gh-navigation .gh-navigation-inner { grid-template-rows: auto 1fr auto; grid-template-columns: 1fr; gap: 48px; } #gh-navigation .gh-navigation-brand { display: grid; grid-template-columns: 1fr auto auto; grid-column-start: 1; align-items: center; height: 64px; } #gh-navigation .gh-navigation-logo { font-size: 2.2rem; } #gh-navigation .gh-navigation-menu, #gh-navigation .gh-navigation-actions { position: fixed; justify-content: center; visibility: hidden; opacity: 0; } #gh-navigation .gh-navigation-menu { transition: none; transform: translateY(0); } #gh-navigation .nav { gap: 20px; align-items: center; line-height: 1.4; } #gh-navigation .nav a { font-size: 2.6rem; font-weight: 600; text-transform: none; } #gh-navigation .nav li { opacity: 0; transform: translateY(-4px); } #gh-navigation .gh-navigation-actions { text-align: center; } #gh-navigation :is(.gh-button, a[data-portal="signin"]) { opacity: 0; transform: translateY(8px); } #gh-navigation .gh-button { width: 100%; font-size: 1.8rem; text-transform: none; } #gh-navigation a[data-portal="signin"] { font-size: 2rem; } #gh-main { transition: opacity 0.4s; } .is-open#gh-navigation { position: fixed; inset: 0; z-index: 3999999; height: 100%; overflow-y: scroll; -webkit-overflow-scrolling: touch; } .is-open#gh-navigation .gh-navigation-menu, .is-open#gh-navigation .gh-navigation-actions { position: static; visibility: visible; opacity: 1; } .is-open#gh-navigation .nav { display: flex; flex-direction: column; } .is-open#gh-navigation .nav li { opacity: 1; transition: transform 0.2s, opacity 0.2s; transform: translateY(0); } .is-open#gh-navigation .gh-navigation-actions { position: sticky; right: 0; bottom: 0; left: 0; display: inline-flex; flex-direction: column; gap: 12px; align-items: center; padding: var(--container-gap) 0 calc(var(--container-gap) + 8px); background-color: var(--color-white); } .is-open#gh-navigation :is(.gh-button, a[data-portal="signin"]) { opacity: 1; transition: transform 0.4s, opacity 0.4s; transition-delay: 0.2s; transform: translateY(0); } .is-open#gh-navigation a[data-portal="signin"] { transition-delay: 0.4s; } .is-open#gh-main { opacity: 0; } } /* Card */ .gh-card { position: relative; } .gh-card-link { display: flex; flex-direction: column; gap: 16px; } .gh-card-link:hover { opacity: 1; } .gh-card-image { position: relative; flex-shrink: 0; aspect-ratio: 16 / 9; } .gh-card-image img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; } .gh-card-wrapper { flex-grow: 1; } .gh-card-tag { display: none; margin-bottom: 4px; font-size: 1.2rem; font-weight: 500; letter-spacing: 0.01em; text-transform: uppercase; } .gh-card-title { font-size: 2rem; letter-spacing: -0.017em; } .gh-card-excerpt { display: -webkit-box; overflow-y: hidden; margin-top: 8px; max-width: 720px; font-size: 1.5rem; line-height: 1.45; -webkit-line-clamp: 3; -webkit-box-orient: vertical; } .gh-card-meta { display: flex; gap: 4px; flex-wrap: wrap; font-size: 1.3rem; font-weight: 500; letter-spacing: -0.0025em; color: var(--color-secondary-text); } .gh-card-meta:not(:empty) { margin-top: 8px; } .gh-card-author + .gh-card-date::before { content: "—"; margin-right: 4px; } /* 6. Header */ .gh-header { position: relative; margin-top: 40px; } .gh-header-image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; } .gh-header-inner { position: relative; } /* 6.1. Magazine layout */ .gh-header.is-magazine .gh-header-inner { display: grid; grid-template-columns: repeat(16, 1fr); gap: var(--grid-gap); } .gh-header.is-magazine .gh-header-inner > div { display: flex; flex-direction: column; gap: var(--grid-gap); grid-row: 1; } .gh-header.is-magazine .gh-header-left { grid-column: 1 / span 4; } .gh-header.is-magazine .gh-header-inner > .gh-card { position: relative; grid-column: 5 / span 8; } .gh-header.is-magazine .gh-header-right { grid-column: 13 / -1; } .gh-header.is-magazine .gh-header-inner > .gh-card .gh-card-link { gap: 20px; } .gh-header.is-magazine .gh-header-inner > .gh-card .gh-card-tag { display: block; margin-bottom: 8px; } .gh-header.is-magazine .gh-header-inner > .gh-card .gh-card-title { font-size: clamp(2rem, 2.73vw + 0.91rem, 4.4rem); line-height: 1.05; letter-spacing: -0.022em; } .gh-header.is-magazine .gh-header-inner > .gh-card .gh-card-excerpt { margin-top: 10px; font-size: 1.7rem; } .gh-header.is-magazine .gh-header-inner > .gh-card .gh-card-meta:not(:empty) { margin-top: 10px; } .gh-header.is-magazine :is(.gh-header-left, .gh-header-right) .gh-card:last-child .gh-card-image { display: none; } .gh-header.is-magazine .gh-header-inner > div .gh-card-excerpt { display: none; } .gh-header.is-magazine .gh-header-inner > .gh-card::before, .gh-header.is-magazine .gh-header-inner > .gh-card::after { position: absolute; top: 0; left: calc(var(--grid-gap) / -2); content: ""; width: 1px; height: 100%; background-color: var(--color-border); } .gh-header.is-magazine .gh-header-inner > .gh-card::after { right: calc(var(--grid-gap) / -2); left: auto; } .gh-header.is-magazine .gh-header-inner > div .gh-card + .gh-card::before { position: absolute; top: calc(var(--grid-gap) / -2); left: 0; content: ""; width: 100%; height: 1px; background-color: var(--color-border); } /* 6.2. Highlight layout */ .gh-header.is-highlight .gh-header-inner { display: grid; grid-template-columns: 3fr 1fr; gap: var(--grid-gap); } .gh-header.is-highlight .gh-card:first-child { grid-row: span 3; } .gh-header.is-highlight .gh-card:first-child .gh-card-link { gap: 20px; } .gh-header.is-highlight .gh-card:first-child .gh-card-image { aspect-ratio: 16 / 10; } .gh-header.is-highlight .gh-card:first-child .gh-card-tag { display: block; margin-bottom: 8px; } .gh-header.is-highlight .gh-card:first-child .gh-card-title { font-size: clamp(2rem, 3.64vw + 0.55rem, 5.2rem); line-height: 1.05; letter-spacing: -0.022em; } .gh-header.is-highlight .gh-card:first-child .gh-card-meta:not(:empty) { margin-top: 14px; } .gh-header.is-highlight .gh-card:not(:first-child) .gh-card-excerpt { display: none; } .gh-header.is-highlight .gh-card:first-child::after { position: absolute; top: 0; right: calc(var(--grid-gap) / -2); content: ""; width: 1px; height: 100%; background-color: var(--color-border); } .gh-header.is-highlight .gh-card:not(:first-child) + .gh-card::before { position: absolute; top: calc(var(--grid-gap) / -2); left: 0; content: ""; width: 100%; height: 1px; background-color: var(--color-border); } /* 6.3. Classic layout */ .gh-header.is-classic { display: flex; min-height: calc(100vh - 100px - 240px); } .gh-header.is-classic .gh-header-inner { display: flex; flex-direction: column; align-items: center; gap: 48px; margin: auto; max-width: 960px; text-align: center; } .gh-header.is-classic.has-image .gh-header-inner { color: #fff; } .gh-header.is-classic .gh-header-title { font-size: clamp(3.2rem, 3.18vw + 1.93rem, 6rem); line-height: 1.1; letter-spacing: -0.022em; } .gh-header.is-classic .gh-header-form { display: flex; align-items: center; position: relative; max-width: 640px; width: 100%; height: 64px; font-size: 1.8rem; letter-spacing: -0.014em; border-radius: 40px; background-color: var(--color-lighter-gray); } .gh-header.is-classic .gh-header-input { padding-inline: 24px; width: 100%; height: 100%; font-size: inherit; letter-spacing: inherit; border: 0; background-color: transparent; } .gh-header.is-classic button.gh-header-input { padding-inline-start: 32px; text-align: left; color: var(--color-secondary-text); } .gh-header.is-classic .gh-button { position: absolute; right: 6px; padding-inline: 40px; height: 52px; font-size: inherit; font-weight: 600; } .gh-header.is-classic svg { position: relative; left: 20px; width: 24px; height: 24px; color: var(--color-secondary-text); } /* 7. Featured posts */ .gh-featured { margin-top: 64px; } .gh-featured-title { margin-bottom: 20px; padding-bottom: 12px; font-size: 1.2rem; font-weight: 500; letter-spacing: 0.01em; text-transform: uppercase; border-bottom: 1px solid var(--color-border); } .gh-featured-feed { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--grid-gap); } .gh-featured-feed .gh-card-link { display: flex; flex-direction: row-reverse; align-items: flex-start; } .gh-featured-feed .gh-card-image { width: 80px; aspect-ratio: 1; } .gh-featured-feed .gh-card-title { font-size: 1.8rem; letter-spacing: -0.011em; } .gh-featured-feed .gh-card-excerpt { display: none; } .gh-featured-feed .gh-card-meta:not(:empty) { flex-direction: column; gap: 0; margin-top: 6px; } .gh-featured-feed .gh-card-date::before { display: none; } .gh-featured-feed .gh-card + .gh-card::before { position: absolute; top: 0; left: calc(var(--grid-gap) / -2); content: ""; width: 1px; height: 100%; background-color: var(--color-border); } /* 8. Container */ .gh-container { margin-top: 64px; } .gh-container-inner { display: grid; grid-template-columns: repeat(16, 1fr); column-gap: var(--grid-gap); } /* 8.1. With sidebar */ .gh-container.has-sidebar .gh-main { grid-column: 1 / span 12; position: relative; } .gh-container.has-sidebar .gh-sidebar { grid-column: 13 / -1; } .gh-container.has-sidebar .gh-main::after { position: absolute; top: 0; right: calc(var(--grid-gap) / -2); content: ""; width: 1px; height: 100%; background-color: var(--color-border); } /* 8.2. Without sidebar */ .gh-container:not(.has-sidebar) .gh-main { grid-column: 3 / span 12; } /* 9. Post list */ .gh-container-title { grid-column: 1 / -1; margin-bottom: 20px; padding-bottom: 12px; font-size: 1.2rem; font-weight: 500; letter-spacing: 0.01em; text-transform: uppercase; border-bottom: 1px solid var(--color-border); } .gh-container .gh-feed { gap: var(--grid-gap); } /* 9.1. List style */ .gh-container.is-list .gh-feed { display: flex; flex-direction: column; } .gh-container.is-list .gh-card-link { flex-direction: row; align-items: flex-start; gap: 24px; } .gh-container.is-list .gh-card-image { flex-shrink: 0; width: 240px; } .gh-container.is-list .gh-card-wrapper { max-width: 600px; } .gh-container.is-list .gh-card + .gh-card::before { position: absolute; top: calc(var(--grid-gap) / -2); left: 0; content: ""; width: 100%; height: 1px; background-color: var(--color-border); } /* 9.2. Grid style */ .gh-container.is-grid .gh-feed { display: grid; grid-template-columns: repeat(3, 1fr); overflow: hidden; } .gh-container.is-grid .gh-card::before { position: absolute; top: calc(var(--grid-gap) / -2); right: calc(var(--grid-gap) / -2); left: calc(var(--grid-gap) / -2); content: ""; height: 1px; background-color: var(--color-border); } .gh-container.is-grid .gh-card::after { position: absolute; top: 0; left: calc(var(--grid-gap) / -2); content: ""; width: 1px; height: 100%; background-color: var(--color-border); } /* 9.3. No image */ .gh-container.is-list.no-image .gh-card-image { display: none; } /* 10. Sidebar */ .gh-about { display: flex; flex-direction: column; align-items: center; padding: 48px 24px; text-align: center; background-color: var(--color-lighter-gray); } .gh-about-icon { margin-bottom: 24px; width: 80px; height: 80px; } .gh-about-title { font-size: 2.4rem; letter-spacing: -0.019em; } .gh-about-description { margin-top: 12px; font-size: 1.4rem; line-height: 1.4; } .gh-about .gh-button { margin-top: 24px; } /* 11. Footer */ .gh-footer { margin-top: 80px; font-size: 1.5rem; color: var(--color-darker-gray); } .gh-footer a:not(.gh-button) { color: inherit; } /* 11.1 Accent color */ .gh-footer.has-accent-color { background-color: var(--ghost-accent-color); color: #fff; } .gh-footer.has-accent-color .gh-button { background-color: #fff; color: #15171a; } /* 11.2. Footer bar */ .gh-footer-bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding-block: 32px; border-block: 1px solid var(--color-border); } .gh-footer-bar a { font-weight: 600; } .gh-footer-logo { position: relative; font-size: 2.6rem; font-weight: 700; letter-spacing: -0.015em; white-space: nowrap; } .gh-footer-menu .nav { display: flex; gap: 24px; margin: 0; padding: 0; list-style-type: none; } .gh-footer-copyright { text-align: right; } /* 11.3. Footer signup */ .gh-footer-signup { display: flex; flex-direction: column; align-items: center; padding-block: 100px; } .gh-footer-signup-header { font-size: clamp(3.2rem, 3.18vw + 1.93rem, 6rem); letter-spacing: -0.022em; } .gh-footer-signup-subhead { font-size: clamp(1.6rem, 1.14vw + 1.15rem, 2.6rem); letter-spacing: -0.02em; color: var(--color-secondary-text); } .gh-footer-signup .gh-button { margin-top: 24px; padding: 16px 40px; font-size: 1.9rem; }