/* styles.css */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #0f2027, #203a43, #2c5364);
    color: #fff;
    min-height: 100vh;
    padding: 0;
}

/* Navigation Container */
.nav-container {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 1.5rem 2rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

/* Logo styling */
.bi-currency-dollar {
    width: 40px;
    height: 40px;
    color: #00c9ff;
    background: linear-gradient(135deg, #00c9ff, #92fe9d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 5px rgba(0, 201, 255, 0.5));
}

/* App heading */
.app-heading {
    font-size: 2.2rem;
    font-weight: 700;
    background: linear-gradient(90deg, #00c9ff, #92fe9d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 2px 10px rgba(0, 201, 255, 0.3);
}

/* Motto text */
.app-motto-header {
    text-align: right;
}

#motto {
    font-size: 0.9rem;
    color: #a0a0a0;
    font-style: italic;
}

/* Main content area */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Hero section */
.hero {
    text-align: center;
    padding: 3rem 0;
    margin-bottom: 2rem;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(90deg, #00c9ff, #92fe9d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.2rem;
    color: #ccc;
    max-width: 600px;
    margin: 0 auto 2rem;
}

/* Controls section */
.controls {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 15px;
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 15px;
}

.search-box {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    padding: 8px 15px;
    width: 300px;
}

.search-box input {
    background: transparent;
    border: none;
    color: white;
    padding: 8px;
    width: 100%;
    outline: none;
    font-size: 1rem;
}

.search-box i {
    color: #a0a0a0;
    margin-right: 8px;
}

.filter-options select {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    padding: 10px 15px;
    border-radius: 20px;
    outline: none;
    cursor: pointer;
}

.filter-options select option {
    background: #2c5364;
}

.refresh-btn {
    background: linear-gradient(90deg, #00c9ff, #92fe9d);
    border: none;
    color: #0f2027;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: opacity 0.3s ease;
}

.refresh-btn:hover {
    opacity: 0.9;
}

/* Crypto grid */
.crypto-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.crypto-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.crypto-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 0.08);
}

.crypto-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.crypto-name {
    display: flex;
    align-items: center;
    gap: 10px;
}

.crypto-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.crypto-symbol {
    color: #a0a0a0;
    text-transform: uppercase;
    font-weight: 600;
}

.crypto-price {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.price-change {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    width: fit-content;
}

.positive {
    color: #00e676;
    background: rgba(0, 230, 118, 0.1);
}

.negative {
    color: #ff5252;
    background: rgba(255, 82, 82, 0.1);
}

.crypto-details {
    margin-top: 15px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.detail-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 10px;
    border-radius: 10px;
    font-size: 0.9rem;
}

.detail-label {
    color: #a0a0a0;
    font-size: 0.8rem;
    margin-bottom: 3px;
}

/* Loading and error states */
.loading {
    text-align: center;
    padding: 40px;
    font-size: 1.2rem;
    color: #a0a0a0;
}

.loading i {
    animation: spin 1s linear infinite;
    margin-right: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error {
    text-align: center;
    padding: 40px;
    color: #ff5252;
    background: rgba(255, 82, 82, 0.1);
    border-radius: 15px;
    margin: 20px 0;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    margin-top: 3rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #a0a0a0;
    font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .app-motto-header {
        text-align: center;
    }
    
    .controls {
        flex-direction: column;
        align-items: center;
    }
    
    .search-box {
        width: 100%;
    }
    
    .crypto-grid {
        grid-template-columns: 1fr;
    }
}

/* Mdeia Queries */
/* Extra Responsive Design */

/* Large desktops (1200px and up) */
@media (min-width: 1200px) {
    main {
        max-width: 1400px;
        padding: 3rem;
    }

    .hero h2 {
        font-size: 3rem;
    }

    .hero p {
        font-size: 1.3rem;
    }

    .crypto-grid {
        grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    }
}

/* Medium desktops & laptops (992px - 1199px) */
@media (max-width: 1199px) and (min-width: 992px) {
    .hero h2 {
        font-size: 2.7rem;
    }

    .crypto-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
}

/* Tablets (768px - 991px) */
@media (max-width: 991px) and (min-width: 768px) {
    .hero h2 {
        font-size: 2.2rem;
    }

    .hero p {
        font-size: 1.1rem;
    }

    .controls {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
    }

    .search-box {
        width: 100%;
    }
}

/* Mobile phones (up to 767px) */
@media (max-width: 767px) {
    .hero h2 {
        font-size: 1.8rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .crypto-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .controls {
        flex-direction: column;
        gap: 15px;
    }

    .refresh-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Small phones (up to 480px) */
@media (max-width: 480px) {
    .nav-container {
        padding: 1rem;
        flex-direction: column;
        gap: 10px;
    }

    .app-heading {
        font-size: 1.5rem;
    }

    .hero h2 {
        font-size: 1.5rem;
    }

    .hero p {
        font-size: 0.9rem;
    }

    .crypto-card {
        padding: 15px;
    }

    .crypto-price {
        font-size: 1.2rem;
    }

    .controls {
        padding: 1rem;
    }

    .search-box {
        padding: 6px 10px;
    }
}


/* APP header css */
/* Group logo + heading */
.logo-container {
    display: flex;
    align-items: center;
    gap: 12px; /* space between logo and text */
}

/* Logo Icon */
.bi-currency-dollar {
    width: 45px;
    height: 45px;
    color: #00c9ff;
    background: linear-gradient(135deg, #00c9ff, #92fe9d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 6px rgba(0, 201, 255, 0.6));
    flex-shrink: 0;
}

/* App Heading */
.app-heading {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(90deg, #00c9ff, #92fe9d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 2px 12px rgba(0, 201, 255, 0.3);
}
