/* Red Beard Peptides - Global Styles */
/* CSS Variables for consistent theming */

:root {
    --primary-color: #ff4444;
    --primary-dark: #cc0000;
    --background-dark: #0a0a0a;
    --background-container: rgba(42, 42, 42, 0.95);
    --background-card: linear-gradient(145deg, #333333 0%, #2a2a2a 100%);
    --text-primary: #ffffff;
    --text-secondary: #cccccc;
    --text-muted: #888888;
    --border-color: #444444;
    --border-hover: #ff4444;
    --success-color: #4ade80;
    --error-color: #f87171;
    --warning-color: #ff9800;
}

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

/* Base Body Styles */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    font-display: swap;
    background: var(--background-dark);
    color: var(--text-primary);
    min-height: 100vh;
    position: relative;
    padding-top: 80px;
}

@media (max-width: 600px) {
    body {
        padding-top: 120px;
    }
}

/* Background Gradient Effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at top left, rgba(255, 68, 68, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at top right, rgba(204, 0, 0, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at bottom left, rgba(255, 68, 68, 0.08) 0%, transparent 50%);
    z-index: 0;
    pointer-events: none;
}

/* Navigation Bar */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, rgba(42, 42, 42, 0.98) 0%, rgba(26, 26, 26, 0.98) 100%);
    backdrop-filter: blur(10px);
    padding: 15px 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    z-index: 9999;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    border-bottom: 2px solid var(--primary-color);
    flex-wrap: wrap;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 15px;
    background: rgba(255, 68, 68, 0.1);
    border: 2px solid transparent;
}

.nav-link:hover {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-color: var(--primary-color);
}

@media (max-width: 600px) {
    nav {
        padding: 10px 15px;
        gap: 8px;
    }
    
    .nav-link {
        padding: 8px 12px;
        font-size: 13px;
    }
}

/* Cart Persistence Indicator */
.cart-saved-indicator {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--success-color);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    opacity: 0;
    transform: translateY(100px);
    transition: all 0.3s ease;
    z-index: 9998;
}

.cart-saved-indicator.show {
    opacity: 1;
    transform: translateY(0);
}

/* Container Styles */
.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: var(--background-container);
    padding: 40px 60px;
    position: relative;
    z-index: 1;
    min-height: 100vh;
    box-shadow: 0 0 100px rgba(0, 0, 0, 0.5);
}

@media (max-width: 768px) {
    .container {
        padding: 20px;
    }
}

/* Headers */
.header {
    text-align: center;
    margin-bottom: 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    padding: 50px 40px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(255,68,68,0.4);
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, 
        transparent 30%, 
        rgba(255,255,255,0.1) 50%, 
        transparent 70%);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

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

.loading-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid #555555;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 8px;
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    display: none;
}

.loading-content {
    background: #2a2a2a;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    border: 2px solid var(--primary-color);
}

.loading-content .spinner-large {
    width: 50px;
    height: 50px;
    border: 4px solid #555555;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

/* Forms */
input[type="text"],
input[type="email"],
input[type="tel"],
textarea,
select {
    width: 100%;
    padding: 14px;
    background-color: #1a1a1a;
    border: 2px solid #555555;
    color: var(--text-primary);
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 15px rgba(255,68,68,0.3);
}

/* Buttons */
.submit-btn {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--text-primary);
    border: none;
    border-radius: 12px;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 20px rgba(255,68,68,0.5);
    animation: pulse 2s infinite;
    text-transform: uppercase;
    letter-spacing: 2px;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 6px 20px rgba(255,68,68,0.5);
    }
    50% {
        box-shadow: 0 8px 30px rgba(255,68,68,0.7);
    }
}

.submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 40px rgba(255,68,68,0.7);
}

.submit-btn:disabled {
    background: linear-gradient(135deg, #666666 0%, #555555 100%);
    cursor: not-allowed;
    animation: none;
}

/* Product Cards */
.product-item {
    background: var(--background-card);
    padding: 20px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    gap: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.product-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(255,68,68,0.4);
    border-color: var(--primary-color);
    background: linear-gradient(145deg, #3a3a3a 0%, #303030 100%);
}

.product-item.selected {
    border-color: var(--primary-color);
    background: linear-gradient(145deg, #3a3a3a 0%, #303030 100%);
    box-shadow: 0 0 20px rgba(255,68,68,0.6);
}

/* Stock Info */
.stock-info {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 8px;
    font-weight: 500;
}

.stock-info.in-stock {
    color: var(--success-color);
}

.stock-info.out-of-stock {
    color: var(--error-color);
    font-weight: bold;
}

/* Messages */
.success-message {
    display: none;
    background-color: #00aa00;
    color: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    text-align: center;
    font-size: 16px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.error-message {
    display: none;
    background-color: #aa0000;
    color: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    text-align: center;
    font-size: 16px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.validation-error {
    color: #ff6666;
    font-size: 13px;
    margin-top: 6px;
    display: none;
}

/* Section Titles */
.section-title {
    font-size: 24px;
    color: var(--primary-color);
    margin: 40px 0 25px 0;
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
    width: 100%;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Logo Animation */
.logo {
    max-width: 400px;
    width: 100%;
    height: auto;
    margin-bottom: 25px;
    position: relative;
    z-index: 1;
    filter: 
        drop-shadow(0 10px 20px rgba(0,0,0,0.6))
        drop-shadow(0 20px 40px rgba(0,0,0,0.4))
        drop-shadow(0 30px 60px rgba(0,0,0,0.3));
    animation: logoFloat 4s ease-in-out infinite;
    transform-style: preserve-3d;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.logo:hover {
    filter: 
        drop-shadow(0 15px 30px rgba(0,0,0,0.7))
        drop-shadow(0 25px 50px rgba(0,0,0,0.5))
        drop-shadow(0 35px 70px rgba(0,0,0,0.4));
    transform: translateY(-15px) scale(1.05);
}

@keyframes logoFloat {
    0%, 100% { 
        transform: translateY(0px) rotateX(0deg) rotateY(0deg);
    }
    25% {
        transform: translateY(-12px) rotateX(2deg) rotateY(-3deg);
    }
    50% { 
        transform: translateY(-18px) rotateX(0deg) rotateY(0deg);
    }
    75% {
        transform: translateY(-12px) rotateX(-2deg) rotateY(3deg);
    }
}

@media (max-width: 480px) {
    .logo {
        max-width: 280px;
    }
}

/* Home Page Specific Styles */
.home-container {
    text-align: center;
    padding: 40px 20px;
    max-width: 900px;
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin: 0 auto;
}

@media (max-width: 600px) {
    .home-container {
        padding: 20px 15px;
        min-height: auto;
        justify-content: flex-start;
        padding-top: 40px;
        padding-bottom: 40px;
    }
}

.logo-container {
    margin-bottom: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-container .logo {
    max-width: 500px;
    cursor: pointer;
}

@media (max-width: 600px) {
    .logo-container .logo {
        max-width: 350px;
    }
}

.welcome-text {
    font-size: 48px;
    font-weight: bold;
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    text-shadow: 0 4px 10px rgba(255,68,68,0.3);
    animation: fadeIn 1s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 600px) {
    .welcome-text {
        font-size: 32px;
    }
}

.tagline {
    font-size: 20px;
    color: #cccccc;
    margin-bottom: 50px;
    line-height: 1.6;
    animation: fadeIn 1.5s ease-in;
}

@media (max-width: 600px) {
    .tagline {
        font-size: 16px;
    }
}

.button-container {
    display: flex;
    gap: 25px;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeIn 2s ease-in;
}

.nav-button {
    padding: 20px 50px;
    font-size: 22px;
    font-weight: bold;
    text-decoration: none;
    color: #ffffff;
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(255,68,68,0.4);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.nav-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.nav-button:hover::before {
    left: 100%;
}

.nav-button:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 35px rgba(255,68,68,0.6);
}

.nav-button:active {
    transform: translateY(-2px);
}

@media (max-width: 600px) {
    .nav-button {
        padding: 18px 40px;
        font-size: 18px;
        width: 100%;
        max-width: 300px;
    }
}

.disclaimer {
    margin-top: 60px;
    font-size: 14px;
    color: #888888;
    line-height: 1.8;
    animation: fadeIn 2.5s ease-in;
}

.disclaimer a {
    color: #ff4444;
    text-decoration: none;
}

.disclaimer a:hover {
    text-decoration: underline;
}

@media (max-width: 600px) {
    .disclaimer {
        font-size: 12px;
    }
}

/* Order Confirmation Page */
.confirmation-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 40px;
    background: var(--background-container);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}

.confirmation-header {
    text-align: center;
    margin-bottom: 40px;
}

.confirmation-icon {
    font-size: 80px;
    color: var(--success-color);
    margin-bottom: 20px;
    animation: scaleIn 0.5s ease-out;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.confirmation-title {
    font-size: 32px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.confirmation-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
}

.order-details-box {
    background: var(--background-card);
    padding: 30px;
    border-radius: 15px;
    margin: 30px 0;
    border: 2px solid var(--primary-color);
}

.order-detail-row {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
}

.order-detail-row:last-child {
    border-bottom: none;
}

.order-detail-label {
    font-weight: 600;
    color: var(--text-secondary);
}

.order-detail-value {
    color: var(--text-primary);
    font-weight: 500;
}

.next-steps {
    background: rgba(255, 68, 68, 0.1);
    padding: 25px;
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
    margin: 30px 0;
}

.next-steps h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.next-steps ol {
    margin-left: 20px;
    line-height: 1.8;
}

.next-steps li {
    margin-bottom: 10px;
}

.action-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
    flex-wrap: wrap;
}

.action-button {
    padding: 15px 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.action-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255,68,68,0.5);
}

.action-button.secondary {
    background: transparent;
    border: 2px solid var(--primary-color);
}

.action-button.secondary:hover {
    background: var(--primary-color);
}
