:root {
    --primary-color: #6366f1;
    --primary-hover: #4f46e5;
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --font-sans: 'Inter', 'Noto Sans KR', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-color);
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header */
.app-header {
    background-color: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.logo-link {
    display: block;
    transition: opacity 0.2s;
}

.logo-link:hover {
    opacity: 0.8;
}

.logo {
    height: 40px;
    width: auto;
    display: block;
}

.app-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.025em;
}

/* Main Content */
.main-container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.counter-card {
    background: var(--card-bg);
    width: 100%;
    max-width: 800px;
    border-radius: 1rem;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.input-wrapper {
    padding: 2rem;
    flex: 1;
}

#textInput {
    width: 100%;
    height: 300px;
    border: none;
    resize: none;
    font-size: 1.125rem;
    font-family: var(--font-sans);
    color: var(--text-main);
    line-height: 1.6;
    outline: none;
}

#textInput::placeholder {
    color: #94a3b8;
}

/* Stats Footer */
.stats-container {
    background-color: #f1f5f9;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-around;
    align-items: center;
    border-top: 1px solid var(--border-color);
}

.stat-box {
    text-align: center;
    flex: 1;
}

.stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
}

.stat-divider {
    width: 1px;
    height: 40px;
    background-color: var(--border-color);
    margin: 0 1rem;
}

/* Footer */
.app-footer {
    text-align: center;
    padding: 1.5rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    border-top: 1px solid var(--border-color);
    background: var(--card-bg);
}

/* Mobile Tweaks */
@media (max-width: 640px) {
    .app-header {
        padding: 0.75rem 1rem;
    }
    
    .logo {
        height: 32px;
    }

    .app-title {
        font-size: 1rem;
    }

    .main-container {
        padding: 1rem;
        align-items: flex-start;
    }

    .stats-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stat-divider {
        width: 100%;
        height: 1px;
        margin: 0;
    }

    .stat-box {
        display: flex;
        justify-content: space-between;
        width: 100%;
        align-items: center;
    }

    .stat-value {
        font-size: 1.5rem;
        margin-bottom: 0;
        order: 2;
    }
    
    .stat-label {
        order: 1;
    }
}
