/* Reset & Base */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --primary: #1a73e8;
    --primary-dark: #1557b0;
    --secondary: #34a853;
    --accent: #fbbc04;
    --dark: #202124;
    --gray: #5f6368;
    --light: #f8f9fa;
    --white: #ffffff;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --radius: 8px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background: var(--light);
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; }
.text-center { text-align: center; }

/* Header & Nav */
header { background: var(--white); box-shadow: var(--shadow); position: sticky; top: 0; z-index: 100; }

.navbar .container { display: flex; justify-content: space-between; align-items: center; height: 70px; }

.logo { font-size: 1.5rem; font-weight: 700; color: var(--primary); }

.nav-menu { display: flex; gap: 30px; }
.nav-menu a { font-weight: 500; color: var(--gray); transition: color 0.3s; }
.nav-menu a:hover { color: var(--primary); }

/* Hero */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, #0d47a1 100%);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
}
.hero h1 { font-size: 3rem; margin-bottom: 20px; }
.hero p { font-size: 1.2rem; opacity: 0.9; margin-bottom: 30px; }
.hero-buttons { display: flex; gap: 15px; justify-content: center; }

/* Buttons */
.btn { padding: 12px 30px; border-radius: var(--radius); font-weight: 600; display: inline-block; transition: all 0.3s; }
.btn-primary { background: var(--accent); color: var(--dark); }
.btn-primary:hover { background: #e6a800; transform: translateY(-2px); }
.btn-secondary { background: var(--white); color: var(--primary); }
.btn-secondary:hover { background: var(--light); }
.btn-outline { border: 2px solid var(--primary); color: var(--primary); background: transparent; }
.btn-outline:hover { background: var(--primary); color: var(--white); }

/* Sections */
section { padding: 60px 0; }
section h2 { font-size: 2rem; text-align: center; margin-bottom: 40px; color: var(--dark); }

.feature-grid, .tool-grid, .article-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }

/* Feature Cards */
.feature-card { background: var(--white); padding: 40px 30px; border-radius: var(--radius); text-align: center; box-shadow: var(--shadow); }
.feature-icon { font-size: 3rem; margin-bottom: 20px; }
.feature-card h3 { margin-bottom: 15px; color: var(--dark); }
.feature-card p { color: var(--gray); }

/* Tool Cards */
.tool-card, .article-card { background: var(--white); padding: 30px; border-radius: var(--radius); box-shadow: var(--shadow); transition: all 0.3s; display: block; }
.tool-card:hover, .article-card:hover { transform: translateY(-5px); box-shadow: 0 5px 20px rgba(0,0,0,0.15); }
.tool-icon { font-size: 2.5rem; margin-bottom: 15px; }
.tool-card h4, .article-card h4 { color: var(--dark); margin-bottom: 10px; }
.tool-card p, .article-card p { color: var(--gray); font-size: 0.9rem; }
.article-card { padding: 25px; }

/* Footer */
footer { background: var(--dark); color: var(--white); padding: 50px 0 20px; }
.footer-content { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px; margin-bottom: 30px; }
.footer-section h4 { margin-bottom: 20px; }
.footer-section ul li { margin-bottom: 10px; }
.footer-section a { color: #aaa; }
.footer-section a:hover { color: var(--white); }
.footer-bottom { text-align: center; padding-top: 20px; border-top: 1px solid #333; color: #888; }

/* Page Header */
.page-header { background: linear-gradient(135deg, var(--primary) 0%, #0d47a1 100%); color: var(--white); padding: 50px 0; text-align: center; }
.page-header h1 { font-size: 2.5rem; margin-bottom: 10px; }
.page-header p { opacity: 0.9; }

/* Tool Page */
.tool-container { background: var(--white); padding: 40px; border-radius: var(--radius); box-shadow: var(--shadow); margin: 40px auto; max-width: 800px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; }
.form-group input, .form-group select { width: 100%; padding: 12px 15px; border: 1px solid #ddd; border-radius: var(--radius); font-size: 1rem; }
.form-group input:focus, .form-group select:focus { outline: none; border-color: var(--primary); }
.result-box { background: var(--light); padding: 20px; border-radius: var(--radius); margin-top: 20px; text-align: center; font-size: 1.2rem; }

/* Article Page */
.article-content { background: var(--white); padding: 40px; border-radius: var(--radius); box-shadow: var(--shadow); margin: 40px auto; max-width: 900px; line-height: 1.8; }
.article-content h2 { text-align: left; margin: 30px 0 15px; color: var(--dark); }
.article-content p { margin-bottom: 15px; color: #333; }
.article-meta { color: var(--gray); font-size: 0.9rem; margin-bottom: 20px; }

/* 404 */
.error-page { text-align: center; padding: 100px 0; }
.error-page h1 { font-size: 6rem; color: var(--primary); }
.error-page h2 { margin-bottom: 20px; }

/* Responsive */
@media (max-width: 768px) {
    .nav-menu { display: none; }
    .hero h1 { font-size: 2rem; }
    .feature-grid, .tool-grid { grid-template-columns: 1fr; }
    .tool-container, .article-content { padding: 20px; margin: 20px; }
}
