Files
burmddit/frontend/app/globals.css
Zeya Phyo 0045e3eab4 Fix critical Burmese typography and layout issues
- Update .font-burmese line-height to 1.85 (critical fix for text overlap)
- Set article content line-height to 2.0 for better readability
- Add Padauk font as fallback for better Myanmar script support
- Update all heading line-heights to 1.75 for proper spacing
- Reduce hero section height (600px → 350px mobile, 450px desktop)
- Improve font-size consistency (1.125rem for body text)

Addresses typography crisis identified in site review.
2026-02-21 08:38:04 +00:00

242 lines
4.6 KiB
CSS

@tailwind base;
@tailwind components;
@tailwind utilities;
/* Modern Design System for Burmddit */
@layer base {
:root {
--primary: #2563eb;
--primary-dark: #1e40af;
--accent: #f59e0b;
}
body {
@apply antialiased bg-gray-50 text-gray-900;
font-feature-settings: "cv11", "ss01";
}
}
/* Burmese Fonts - Better rendering */
@font-face {
font-family: 'Pyidaungsu';
src: url('https://myanmar-tools-website.appspot.com/fonts/Pyidaungsu-2.5.3_Regular.ttf') format('truetype');
font-weight: 400;
font-display: swap;
font-feature-settings: "liga" 1;
}
@font-face {
font-family: 'Pyidaungsu';
src: url('https://myanmar-tools-website.appspot.com/fonts/Pyidaungsu-2.5.3_Bold.ttf') format('truetype');
font-weight: 700;
font-display: swap;
}
.font-burmese {
font-family: 'Pyidaungsu', 'Noto Sans Myanmar', 'Padauk', 'Myanmar Text', sans-serif;
letter-spacing: 0.01em;
line-height: 1.85;
}
.font-burmese p,
.font-burmese .article-body {
line-height: 2.0;
font-size: 1.125rem;
}
.font-burmese h1,
.font-burmese h2,
.font-burmese h3 {
line-height: 1.75;
}
/* Modern Card Design */
.card {
@apply bg-white rounded-xl shadow-sm hover:shadow-xl transition-all duration-300 overflow-hidden border border-gray-100;
}
.card-hover {
@apply transform hover:-translate-y-1 hover:scale-[1.02];
}
/* Tag/Hashtag Design */
.tag {
@apply inline-flex items-center px-3 py-1 rounded-full text-xs font-medium;
@apply bg-blue-50 text-blue-600 hover:bg-blue-600 hover:text-white;
@apply transition-all duration-200 cursor-pointer;
}
.tag-burmese {
@apply font-burmese text-sm;
}
/* Article Content - Better Typography */
.article-content {
@apply font-burmese text-gray-800;
font-size: 1.125rem;
line-height: 2.0;
}
.article-content h1 {
@apply text-4xl font-bold mt-10 mb-6 text-gray-900 font-burmese;
line-height: 1.75;
}
.article-content h2 {
@apply text-3xl font-bold mt-8 mb-5 text-gray-900 font-burmese;
line-height: 1.75;
}
.article-content h3 {
@apply text-2xl font-semibold mt-6 mb-4 text-gray-800 font-burmese;
line-height: 1.75;
}
.article-content p {
@apply mb-6 text-lg leading-loose text-gray-700;
}
.article-content a {
@apply text-blue-600 hover:text-blue-800 underline decoration-2 underline-offset-2 transition-colors duration-200;
}
.article-content ul,
.article-content ol {
@apply ml-6 mb-6 space-y-3;
}
.article-content li {
@apply text-lg text-gray-700 leading-relaxed pl-2;
}
.article-content ul li {
@apply list-disc;
}
.article-content ol li {
@apply list-decimal;
}
.article-content code {
@apply bg-gray-100 px-2 py-1 rounded text-sm font-mono text-gray-800 border border-gray-200;
}
.article-content pre {
@apply bg-gray-900 text-gray-100 p-5 rounded-xl overflow-x-auto mb-6 shadow-lg;
}
.article-content blockquote {
@apply border-l-4 border-blue-600 pl-6 italic my-6 text-gray-700 bg-blue-50 py-4 rounded-r-lg;
}
/* Image Zoom on Hover */
.image-zoom {
@apply overflow-hidden;
}
.image-zoom img {
@apply transition-transform duration-500 ease-out;
}
.image-zoom:hover img {
@apply scale-110;
}
/* Loading Skeleton */
.skeleton {
@apply animate-pulse bg-gradient-to-r from-gray-200 via-gray-300 to-gray-200;
animation: shimmer 1.5s infinite;
}
@keyframes shimmer {
0% { background-position: -200% 0; }
100% { background-position: 200% 0; }
}
/* Smooth Page Transitions */
@keyframes fadeIn {
from { opacity: 0; transform: translateY(10px); }
to { opacity: 1; transform: translateY(0); }
}
.fade-in {
animation: fadeIn 0.4s ease-out;
}
/* Badge Design */
.badge {
@apply inline-flex items-center px-3 py-1 rounded-full text-xs font-semibold shadow-sm;
}
.badge-primary {
@apply bg-blue-600 text-white;
}
.badge-accent {
@apply bg-orange-500 text-white;
}
/* Hover Effects */
.hover-lift {
@apply transition-all duration-300;
}
.hover-lift:hover {
@apply transform -translate-y-2 shadow-2xl;
}
/* Focus Styles */
*:focus-visible {
@apply outline-none ring-2 ring-blue-600 ring-offset-2 rounded;
}
/* Scrollbar Styling */
::-webkit-scrollbar {
width: 10px;
height: 10px;
}
::-webkit-scrollbar-track {
@apply bg-gray-100;
}
::-webkit-scrollbar-thumb {
@apply bg-gray-400 rounded-full;
}
::-webkit-scrollbar-thumb:hover {
@apply bg-gray-500;
}
/* Mobile Optimizations */
@media (max-width: 640px) {
.article-content {
font-size: 1rem;
line-height: 1.8;
}
.article-content h1 {
@apply text-3xl;
}
.article-content h2 {
@apply text-2xl;
}
.article-content h3 {
@apply text-xl;
}
}
/* Print Styles */
@media print {
.no-print {
display: none !important;
}
.article-content {
@apply text-black;
}
}