migrate to tailwindv4

This commit is contained in:
2026-06-06 10:22:12 +05:30
parent 9d700baccc
commit 4f70c77874
7 changed files with 793 additions and 959 deletions

View File

@@ -1,111 +1,114 @@
:root {
--text: #6b6375;
--text-h: #08060d;
--bg: #fff;
--border: #e5e4e7;
--code-bg: #f4f3ec;
--accent: #aa3bff;
--accent-bg: rgba(170, 59, 255, 0.1);
--accent-border: rgba(170, 59, 255, 0.5);
--social-bg: rgba(244, 243, 236, 0.5);
--shadow:
rgba(0, 0, 0, 0.1) 0 10px 15px -3px, rgba(0, 0, 0, 0.05) 0 4px 6px -2px;
@import "tailwindcss";
--sans: system-ui, 'Segoe UI', Roboto, sans-serif;
--heading: system-ui, 'Segoe UI', Roboto, sans-serif;
--mono: ui-monospace, Consolas, monospace;
@theme {
--color-brew-bg: #FAF6F1;
--color-brew-bg2: #F3EDE4;
--color-brew-card: #FFFFFF;
--color-brew-text: #2C1810;
--color-brew-text2: #6B5744;
--color-brew-text3: #9C8B7A;
--color-brew-accent: #8B6914;
--color-brew-accent2: #C4941A;
--color-brew-border: #E8DFD3;
--color-brew-espresso: #5C3317;
--color-brew-coldbrew: #2F4F6F;
--color-brew-pourover: #8B6914;
--color-brew-danger: #B44040;
--color-brew-success: #4A7C59;
font: 18px/145% var(--sans);
letter-spacing: 0.18px;
color-scheme: light dark;
color: var(--text);
background: var(--bg);
font-synthesis: none;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
--font-serif: "Playfair Display", serif;
--font-sans: "Source Sans 3", sans-serif;
@media (max-width: 1024px) {
font-size: 16px;
--radius-sm: 8px;
--radius-md: 12px;
--radius-lg: 20px;
--shadow-card: 0 1px 3px rgba(44,24,16,0.06), 0 4px 12px rgba(44,24,16,0.04);
--shadow-card-lg: 0 4px 16px rgba(44,24,16,0.08), 0 12px 32px rgba(44,24,16,0.06);
}
@layer base {
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html {
scrollbar-gutter: stable;
font-family: "Source Sans 3", sans-serif;
background-color: #F3EDE4;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
body {
margin: 0;
background-color: #F3EDE4;
}
#root {
width: 100%;
min-height: 100svh;
display: flex;
flex-direction: column;
box-sizing: border-box;
}
input, select, textarea {
font-family: "Source Sans 3", sans-serif;
}
button {
font-family: "Source Sans 3", sans-serif;
}
}
@media (prefers-color-scheme: dark) {
:root {
--text: #9ca3af;
--text-h: #f3f4f6;
--bg: #16171d;
--border: #2e303a;
--code-bg: #1f2028;
--accent: #c084fc;
--accent-bg: rgba(192, 132, 252, 0.15);
--accent-border: rgba(192, 132, 252, 0.5);
--social-bg: rgba(47, 48, 58, 0.5);
--shadow:
rgba(0, 0, 0, 0.4) 0 10px 15px -3px, rgba(0, 0, 0, 0.25) 0 4px 6px -2px;
@layer utilities {
.font-serif {
font-family: "Playfair Display", serif;
}
#social .button-icon {
filter: invert(1) brightness(2);
.font-sans-brew {
font-family: "Source Sans 3", sans-serif;
}
/* Sync badge pulse animation */
.animate-sync-pulse {
animation: sync-pulse 1.5s infinite;
}
@keyframes sync-pulse {
0%, 100% { opacity: 0.3; }
50% { opacity: 1; }
}
/* Modal animations */
.animate-fade-in {
animation: fade-in 0.2s ease-out;
}
@keyframes fade-in {
from { opacity: 0; }
to { opacity: 1; }
}
.animate-slide-up {
animation: slide-up 0.3s ease-out;
}
@keyframes slide-up {
from { transform: translateY(100%); }
to { transform: translateY(0); }
}
/* Brew method bar */
.brew-method-bar {
position: absolute;
left: 0;
top: 12px;
bottom: 12px;
width: 4px;
border-radius: 0 4px 4px 0;
}
}
body {
margin: 0;
}
#root {
width: 1126px;
max-width: 100%;
margin: 0 auto;
text-align: center;
border-inline: 1px solid var(--border);
min-height: 100svh;
display: flex;
flex-direction: column;
box-sizing: border-box;
}
h1,
h2 {
font-family: var(--heading);
font-weight: 500;
color: var(--text-h);
}
h1 {
font-size: 56px;
letter-spacing: -1.68px;
margin: 32px 0;
@media (max-width: 1024px) {
font-size: 36px;
margin: 20px 0;
}
}
h2 {
font-size: 24px;
line-height: 118%;
letter-spacing: -0.24px;
margin: 0 0 8px;
@media (max-width: 1024px) {
font-size: 20px;
}
}
p {
margin: 0;
}
code,
.counter {
font-family: var(--mono);
display: inline-flex;
border-radius: 4px;
color: var(--text-h);
}
code {
font-size: 15px;
line-height: 135%;
padding: 4px 8px;
background: var(--code-bg);
}