body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #0b0d2c;
    color: white;
}

html {
    overflow-y:scroll;
}

/* Login */

.logo-container {
  text-align: center;
  margin-bottom: 40px;
}

.logo {
  max-width: 70%;
  height: auto;
}


/* Header */
.top-bar {
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    background-color: #0b0d2c;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 1000;
    height: 50px;
}

.top-bar h1 {
    margin: 0;
    font-size: 20px;
    font-weight: bold;
}

.top-bar a {
    text-decoration: none;
}

.add-btn {
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 20px;
    line-height: 28px;
    text-align: center;
    cursor: pointer;
    padding: 0;
}

/* Annoucement block */

.announcement-bar {
    background-color: #1c1f3a;
    color: #68aaff;
    padding: 12px;
    text-align: center;
    font-size: 14px;
    font-weight: bold;
    border-radius: 8px;
    margin-left: 20px;
    margin-right: 20px;
}

/* Footer */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #0b0d2c;
    display: flex;
    justify-content: space-around;
    padding: 12px 0;
    font-weight: bold;
    font-size: 14px;
    z-index: 1000;
}

/* Main content spacing */
.content {
    padding: 0px 20px 20px 20px;
    opacity: 0;
    transition: opacity 1s;
    animation: fadeInAnimation ease 1s;
    animation-iteration-count: 1;
    animation-fill-mode: forwards;
}

@keyframes fadeInAnimation {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
        }
}

section {
    margin-bottom: 30px;
}

h2 {
    font-size: 14px;
    font-weight: bold;
    margin: 10px 0;
}

/* Grid and card styles */
.card-grid {
    display: grid;
    gap: 20px;
}

.favorites .card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 20px;
    justify-i2tems: center;
}

.all-cards .card-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* fixed 2-column layout */
    gap: 20px;
}

.card {
    background-color: #ccc;
    border-radius: 12px;
    aspect-ratio: 1.586 / 1;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
}

.card img {
    display: block;
    margin: 0 auto;
    object-fit: contain;
    width: 100%;
    height: 100%;
}

.store-search {
    background: #0b0d2c;
    position: sticky;
    top: 74px;
    z-index: 998;
    padding: 0px 20px 20px 20px;
}

.store-search input {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    border-radius: 12px;
    border: none;
    background: #1c1f3a;
    color: white;
    box-sizing: border-box;
}
    
.store-search input:focus-visible {
    outline: none;
    border: none;
}

.store-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    padding-top: 0px;
}

.store-box {
    border-radius: 12px;
    aspect-ratio: 1.586 / 1;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
    }

.store-box img {
    display: block;
    margin: 0 auto;
    object-fit: contain;
    width: 100%;
    height: 100%;
}

.top-bar .left {
    font-weight: bold;
    font-size: 20px;
}

.top-bar .right {
    display: flex;
    gap: 12px;
    align-items: center;
}

.top-bar .right a, .top-bar .right button {
    color: white;
    font-size: 18px;
    background: none;
    border: none;
    cursor: pointer;
}

.dropdown {
    position: absolute;
    top: 50px;
    right: 16px;
    background: #1c1f3a;
    border-radius: 10px;
    overflow: hidden;
    display: none;
    flex-direction: column;
    z-index: 1000;
}

.dropdown a {
    color: white;
    padding: 12px;
    text-decoration: none;
    border-bottom: 1px solid #333;
}

.dropdown a:last-child {
    border-bottom: none;
}

.viewcard-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
height: calc(100vh - 74px);
    transition: opacity 1s;
    animation: fadeInAnimation ease 1s;
    animation-iteration-count: 1;
    animation-fill-mode: forwards;
}
    
.store-logo img {
    display: block;
    margin: 0 auto;
    object-fit: contain;
    max-width: 100%;
    width: 100%;
    height: auto;
    max-width: 25vh;
    margin-bottom: 20px;
}

.barcode {
    background: white;
    padding: 16px;
    border-radius: 10px;
    margin-top: 40px;
    max-width: 50vh;
}

.barcode img {
    max-width: 100%;
    height: auto;
}

/* Auth forms */
.auth-container {
    max-width: 320px;
    margin: 80px auto 0;
    padding: 20px;
    background-color: #0b0d2c;
    color: white;
    text-align: center;
    opacity: 0;
    transition: opacity 1s;
    animation: fadeInAnimation ease 1s;
    animation-iteration-count: 1;
    animation-fill-mode: forwards;
}

.auth-container h1 {
    font-size: 24px;
    margin-bottom: 20px;
}

.auth-container form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-container input {
    padding: 14px;
    font-size: 16px;
    border: none;
    border-radius: 10px;
    background-color: #1c1f3a;
    color: white;
    outline: none;
    -webkit-appearance: none;
}

.auth-container input::placeholder {
    color: #ccc;
}

.auth-container button {
    padding: 14px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.auth-container button:hover {
    background-color: #005fd1;
}

.auth-container .links {
    margin-top: 15px;
    display: flex;
    justify-content: space-between;
    font-size: 14px;
}

.auth-container .links a {
    color: #68aaff;
    text-decoration: none;
}
