:root {
    --primary-color: #4285f4;
    --primary-dark: #3367d6;
    --secondary-color: #34a853;
    --text-primary: #202124;
    --text-secondary: #5f6368;
    --background: #ffffff;
    --background-alt: #f8f9fa;
    --border-color: #e8eaed;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.15);
    --radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--background-alt);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 40px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.developer-info {
    flex: 1;
    min-width: 250px;
}

.developer-name {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.developer-title {
    font-size: 1.125rem;
    opacity: 0.9;
    font-weight: 400;
}

.play-store-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius);
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    white-space: nowrap;
}

.play-store-link:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.play-store-link svg {
    width: 20px;
    height: 20px;
}

/* Main Content */
.main {
    padding: 60px 0;
    min-height: calc(100vh - 200px);
}

.intro-section {
    text-align: center;
    margin-bottom: 50px;
}

.section-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.section-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Loading State */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 20px;
    color: var(--text-secondary);
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading p {
    font-size: 1rem;
    font-weight: 500;
}

/* Error State */
.error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 20px;
    text-align: center;
    color: var(--text-secondary);
}

.error svg {
    color: #ea4335;
    margin-bottom: 20px;
}

.error h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.error p {
    font-size: 1rem;
    margin-bottom: 24px;
    max-width: 400px;
}

.retry-btn {
    padding: 12px 32px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}

.retry-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Apps Grid */
.apps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.app-card {
    background: var(--background);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    cursor: pointer;
    border: 1px solid var(--border-color);
}

.app-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.app-icon-container {
    width: 100%;
    padding: 24px;
    background: var(--background-alt);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
}

.app-icon {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.app-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.app-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.app-description {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 16px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.app-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: var(--transition);
    margin-top: auto;
    justify-content: center;
}

.app-link:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(66, 133, 244, 0.3);
}

.app-link svg {
    width: 16px;
    height: 16px;
}

/* Footer */
.footer {
    background: var(--background);
    border-top: 1px solid var(--border-color);
    padding: 32px 0;
    margin-top: 60px;
    text-align: center;
    color: var(--text-secondary);
}

.footer p {
    margin-bottom: 8px;
    font-size: 0.9375rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header {
        padding: 30px 0;
    }

    .developer-name {
        font-size: 2rem;
    }

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

    .play-store-link {
        padding: 10px 20px;
        font-size: 0.9375rem;
    }

    .main {
        padding: 40px 0;
    }

    .section-title {
        font-size: 1.875rem;
    }

    .section-description {
        font-size: 1rem;
    }

    .apps-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 20px;
    }

    .app-icon-container {
        min-height: 180px;
        padding: 20px;
    }

    .app-icon {
        width: 100px;
        height: 100px;
    }
}

@media (max-width: 480px) {
    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .play-store-link {
        width: 100%;
        justify-content: center;
    }

    .developer-name {
        font-size: 1.75rem;
    }

    .apps-grid {
        grid-template-columns: 1fr;
    }

    .app-icon-container {
        min-height: 160px;
    }

    .app-icon {
        width: 80px;
        height: 80px;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for accessibility */
a:focus,
button:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}
