/* PixelCraft - Main Styles */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #7c3aed;
  --primary-light: #a855f7;
  --primary-dark: #5b21b6;
  --accent: #2dd4bf;
  --bg: #ffffff;
  --bg-secondary: #f8fafc;
  --card-bg: #ffffff;
  --text: #0f172a;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --shadow: 0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -2px rgba(0,0,0,.1);
  --shadow-lg: 0 20px 25px -5px rgba(0,0,0,.1), 0 8px 10px -6px rgba(0,0,0,.1);
  --radius: 12px;
  --radius-sm: 8px;
  font-family: 'Poppins', sans-serif;
}

body { background: var(--bg); color: var(--text); line-height: 1.6; }

/* Navbar */
.navbar { position: fixed; top: 0; left: 0; right: 0; z-index: 100; padding: 0 2rem; height: 70px; display: flex; align-items: center; background: rgba(255,255,255,0.95); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
.nav-container { max-width: 1200px; margin: 0 auto; width: 100%; display: flex; align-items: center; justify-content: space-between; }
.nav-logo { font-size: 1.4rem; font-weight: 700; color: var(--primary); text-decoration: none; display: flex; align-items: center; gap: 8px; }
.nav-logo i { font-size: 1.2rem; }
.nav-links { display: flex; align-items: center; gap: 12px; }

/* Buttons */
.btn { padding: 8px 20px; border-radius: var(--radius-sm); font-size: .9rem; font-weight: 500; font-family: inherit; cursor: pointer; border: none; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; transition: all .2s; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(124,58,237,.3); }
.btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-ghost { background: transparent; color: var(--text); }
.btn-ghost:hover { background: var(--bg-secondary); }
.btn-hero-primary { padding: 14px 32px; font-size: 1rem; background: var(--primary); color: #fff; border-radius: 50px; box-shadow: 0 4px 20px rgba(124,58,237,.35); }
.btn-hero-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(124,58,237,.4); }
.btn-hero-secondary { padding: 14px 32px; font-size: 1rem; background: transparent; color: var(--text); border: 2px solid var(--border); border-radius: 50px; }
.btn-hero-secondary:hover { border-color: var(--primary); color: var(--primary); }
.btn-cta { padding: 16px 40px; font-size: 1.1rem; font-weight: 600; background: #fff; color: var(--primary); border-radius: 50px; display: inline-flex; align-items: center; gap: 8px; }
.btn-cta:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0,0,0,.15); }

/* Hero */
.hero { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 100px 2rem 60px; background: linear-gradient(135deg, #f8fafc 0%, #f0f4ff 50%, #faf5ff 100%); position: relative; overflow: hidden; gap: 4rem; max-width: 1300px; margin: 0 auto; }
.hero-bg-shapes { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.shape { position: absolute; border-radius: 50%; opacity: .07; }
.shape-1 { width: 600px; height: 600px; background: var(--primary); top: -200px; right: -200px; }
.shape-2 { width: 400px; height: 400px; background: var(--accent); bottom: -150px; left: -100px; }
.shape-3 { width: 200px; height: 200px; background: #f59e0b; top: 50%; left: 40%; }
.hero-content { flex: 1; max-width: 560px; position: relative; z-index: 1; }
.hero-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(124,58,237,.1); color: var(--primary); padding: 6px 16px; border-radius: 50px; font-size: .85rem; font-weight: 600; margin-bottom: 20px; border: 1px solid rgba(124,58,237,.2); }
.hero-title { font-size: clamp(2.5rem, 5vw, 3.8rem); font-weight: 800; line-height: 1.1; margin-bottom: 20px; }
.gradient-text { background: linear-gradient(135deg, var(--primary), var(--accent)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-subtitle { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 32px; line-height: 1.8; }
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 40px; }
.hero-stats { display: flex; align-items: center; gap: 20px; }
.stat-item { text-align: center; }
.stat-item strong { display: block; font-size: 1.5rem; font-weight: 700; color: var(--text); }
.stat-item span { font-size: .8rem; color: var(--text-muted); }
.stat-divider { width: 1px; height: 40px; background: var(--border); }
.hero-visual { flex: 1; max-width: 500px; display: flex; justify-content: center; position: relative; z-index: 1; }

/* Editor Preview Card */
.editor-preview-card { background: #1a1a2e; border-radius: 16px; overflow: hidden; width: 100%; max-width: 420px; box-shadow: 0 40px 80px rgba(0,0,0,.25); border: 1px solid rgba(255,255,255,.1); }
.editor-preview-header { display: flex; align-items: center; gap: 6px; padding: 12px 16px; background: #16213e; }
.dot { width: 12px; height: 12px; border-radius: 50%; display: inline-block; }
.dot.red { background: #ff5f57; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #28c840; }
.title-bar { flex: 1; text-align: center; font-size: .8rem; color: #64748b; font-weight: 500; }
.editor-preview-body { display: flex; padding: 12px; gap: 10px; }
.preview-toolbar { display: flex; flex-direction: column; gap: 8px; }
.tool-btn-p { width: 36px; height: 36px; background: rgba(255,255,255,.05); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #64748b; font-size: .9rem; cursor: pointer; }
.tool-btn-p.active { background: var(--primary); color: #fff; }
.preview-canvas { flex: 1; background: #0f172a; border-radius: 8px; min-height: 150px; display: flex; align-items: center; justify-content: center; }
.canvas-placeholder { text-align: center; color: #334155; }
.canvas-placeholder i { font-size: 2rem; display: block; margin-bottom: 8px; }
.canvas-placeholder span { font-size: .75rem; }
.preview-sidebar { width: 100px; display: flex; flex-direction: column; gap: 6px; }
.sidebar-item { background: rgba(255,255,255,.05); color: #94a3b8; font-size: .7rem; padding: 8px; border-radius: 6px; cursor: pointer; }
.sidebar-item.active { background: rgba(124,58,237,.3); color: #c084fc; }
.preview-toolbar .tool-btn { width: 36px; height: 36px; background: rgba(255,255,255,.05); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #64748b; font-size: .85rem; cursor: pointer; border: none; }
.preview-toolbar .tool-btn.active { background: var(--primary); color: #fff; }

/* Features */
.features { padding: 100px 2rem; background: var(--bg-secondary); }
.container { max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 60px; }
.section-header h2 { font-size: 2.5rem; font-weight: 700; margin-bottom: 12px; }
.section-header p { font-size: 1.1rem; color: var(--text-muted); }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }
.feature-card { background: var(--card-bg); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); border: 1px solid var(--border); transition: transform .3s, box-shadow .3s; }
.feature-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.feature-icon { width: 56px; height: 56px; border-radius: 16px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; color: #fff; margin-bottom: 20px; }
.feature-card h3 { font-size: 1.2rem; font-weight: 600; margin-bottom: 12px; }
.feature-card p { color: var(--text-muted); font-size: .95rem; line-height: 1.7; }

/* How it works */
.how-it-works { padding: 100px 2rem; }
.steps-grid { display: flex; align-items: center; justify-content: center; gap: 20px; flex-wrap: wrap; }
.step-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 40px 30px; text-align: center; max-width: 250px; flex: 1; }
.step-number { font-size: 3rem; font-weight: 800; color: var(--primary); opacity: .2; margin-bottom: 16px; }
.step-card h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: 8px; }
.step-card p { font-size: .9rem; color: var(--text-muted); }
.step-arrow { font-size: 1.5rem; color: var(--border); }

/* CTA */
.cta-section { padding: 80px 2rem; }
.cta-card { background: linear-gradient(135deg, var(--primary), #9333ea, var(--primary-light)); border-radius: 24px; padding: 80px 40px; text-align: center; color: #fff; }
.cta-card h2 { font-size: 2.5rem; font-weight: 700; margin-bottom: 16px; }
.cta-card p { font-size: 1.1rem; opacity: .9; margin-bottom: 32px; }

/* Footer */
.footer { background: #0f172a; color: #94a3b8; padding: 40px 2rem 20px; }
.footer .container { max-width: 1200px; margin: 0 auto; }
.footer-content { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; flex-wrap: wrap; padding-bottom: 24px; border-bottom: 1px solid #1e293b; margin-bottom: 24px; }
.footer-brand .nav-logo { color: #e2e8f0; }
.footer-brand p { margin-top: 8px; font-size: .9rem; }
.footer-links { display: flex; gap: 24px; }
.footer-links a { color: #64748b; text-decoration: none; font-size: .9rem; }
.footer-links a:hover { color: #e2e8f0; }
.footer-bottom { text-align: center; font-size: .85rem; }

/* Auth Pages */
.auth-page { min-height: 100vh; display: flex; }
.auth-container { display: flex; width: 100%; min-height: 100vh; }
.auth-left { flex: 1; background: linear-gradient(135deg, var(--primary-dark), var(--primary), #9333ea); padding: 60px 50px; display: flex; align-items: center; color: #fff; }
.auth-left-content { max-width: 400px; }
.auth-logo { font-size: 1.5rem; font-weight: 700; color: #fff; text-decoration: none; display: flex; align-items: center; gap: 8px; margin-bottom: 50px; }
.auth-left h2 { font-size: 2rem; font-weight: 700; margin-bottom: 16px; }
.auth-left p { font-size: 1rem; opacity: .85; margin-bottom: 40px; }
.auth-features { display: flex; flex-direction: column; gap: 14px; }
.auth-feature { display: flex; align-items: center; gap: 10px; font-size: .95rem; }
.auth-feature i { color: #86efac; }
.auth-right { flex: 1; display: flex; align-items: center; justify-content: center; padding: 40px; background: var(--bg); }
.auth-form-container { width: 100%; max-width: 420px; }
.auth-form-container h1 { font-size: 2rem; font-weight: 700; margin-bottom: 8px; }
.auth-subtitle { color: var(--text-muted); margin-bottom: 32px; }
.auth-form { display: flex; flex-direction: column; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: .9rem; font-weight: 500; color: var(--text); display: flex; align-items: center; gap: 6px; }
.form-group label i { color: var(--primary); }
.form-group input { padding: 12px 16px; border: 2px solid var(--border); border-radius: var(--radius-sm); font-size: .95rem; font-family: inherit; transition: border-color .2s, box-shadow .2s; outline: none; background: var(--bg); color: var(--text); }
.form-group input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,58,237,.1); }
.input-with-toggle { position: relative; }
.input-with-toggle input { width: 100%; padding-right: 44px; }
.toggle-pass { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: .9rem; }
.btn-auth { padding: 14px; background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm); font-size: 1rem; font-weight: 600; font-family: inherit; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; transition: background .2s; }
.btn-auth:hover:not(:disabled) { background: var(--primary-dark); }
.btn-auth:disabled { opacity: .7; cursor: not-allowed; }
.auth-switch { text-align: center; margin-top: 24px; font-size: .9rem; color: var(--text-muted); }
.auth-switch a { color: var(--primary); text-decoration: none; font-weight: 600; }
.password-strength { height: 4px; background: var(--border); border-radius: 2px; margin-top: 6px; overflow: hidden; }
.strength-fill { height: 100%; width: 0; transition: width .3s, background .3s; border-radius: 2px; }
.strength-text { font-size: .8rem; font-weight: 500; }

/* Alerts */
.alert { padding: 12px 16px; border-radius: var(--radius-sm); font-size: .9rem; font-weight: 500; margin-bottom: 16px; }
.alert-success { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.alert-error { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.hidden { display: none !important; }
