diff --git a/src/App.css b/src/App.css index 350c4001..72dc7379 100644 --- a/src/App.css +++ b/src/App.css @@ -2,40 +2,193 @@ display: flex; flex-direction: column; align-items: center; - justify-content: center; + justify-content: flex-start; + min-height: 100vh; + padding: 2rem 1rem; + max-width: 1200px; + margin: 0 auto; } -.App-logo { - height: 40vmin; - pointer-events: none; +.app-header { + text-align: center; + margin-bottom: 2rem; + width: 100%; } -@media (prefers-reduced-motion: no-preference) { - .App-logo { - animation: App-logo-spin infinite 20s linear; - } +.app-header h1 { + color: #ffffff; + font-size: 2.5rem; + font-weight: 700; + margin: 0 0 0.5rem 0; + text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2); + letter-spacing: -0.5px; } -.App-header { - background-color: #282c34; - min-height: 100vh; +.app-header p { + color: #ffffff; + font-size: 1.2rem; + margin: 0; + opacity: 0.95; + font-weight: 300; +} + +.cart-container { + background: #ffffff; + border-radius: 16px; + box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15); + padding: 2rem; + width: 100%; + margin-bottom: 2rem; + transition: transform 0.3s ease, box-shadow 0.3s ease; +} + +.cart-container:hover { + transform: translateY(-2px); + box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2); +} + +.shipping-container { + background: #ffffff; + border-radius: 16px; + box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15); + padding: 2rem; + width: 100%; + margin-bottom: 2rem; +} + +.purchase-button { + background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); + color: white; + border: none; + padding: 1rem 3rem; + font-size: 1.1rem; + font-weight: 600; + border-radius: 12px; + cursor: pointer; + box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4); + transition: all 0.3s ease; + text-transform: uppercase; + letter-spacing: 1px; + width: 100%; + max-width: 400px; + margin: 0 auto; + display: block; +} + +.purchase-button:hover { + transform: translateY(-2px); + box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6); + background: linear-gradient(135deg, #764ba2 0%, #667eea 100%); +} + +.purchase-button:active { + transform: translateY(0); + box-shadow: 0 2px 10px rgba(102, 126, 234, 0.4); +} + +.cart-items-list { + list-style-type: none; + padding: 0; + margin: 0; display: flex; flex-direction: column; + gap: 1rem; +} + +.cart-summary { + background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%); + border-radius: 12px; + padding: 1.5rem; + margin-top: 2rem; + border: 1px solid rgba(0, 0, 0, 0.05); +} + +.cart-summary p { + margin: 0.75rem 0; + font-size: 1rem; + color: #333; + display: flex; + justify-content: space-between; align-items: center; - justify-content: center; - font-size: calc(10px + 2vmin); - color: white; } -.App-link { - color: #61dafb; +.cart-summary hr { + border: none; + border-top: 2px solid rgba(102, 126, 234, 0.3); + margin: 1rem 0; +} + +.cart-summary .order-total { + font-size: 1.5rem; + font-weight: 700; + color: #667eea; + margin-top: 1rem; + padding-top: 1rem; + border-top: 2px solid rgba(102, 126, 234, 0.3); +} + +.cart-title { + color: #333; + font-size: 2rem; + font-weight: 700; + margin: 0 0 1.5rem 0; + padding-bottom: 1rem; + border-bottom: 3px solid #667eea; +} + +.shipping-title { + color: #333; + font-size: 1.5rem; + font-weight: 600; + margin: 0 0 1.5rem 0; +} + +.loading-text, +.error-text { + text-align: center; + padding: 2rem; + color: #333; + font-size: 1.2rem; +} + +.error-text { + color: #e74c3c; + background: #ffeaea; + border-radius: 8px; + border-left: 4px solid #e74c3c; } -@keyframes App-logo-spin { - from { - transform: rotate(0deg); +.shipping-option-label { + display: flex; + align-items: center; + padding: 1rem; + border-radius: 8px; + border: 2px solid #e0e0e0; + transition: all 0.3s ease; + cursor: pointer; +} + +.shipping-option-label:hover { + border-color: #667eea; + background-color: #f8f9ff; +} + +@media (max-width: 768px) { + .App { + padding: 1rem 0.5rem; } - to { - transform: rotate(360deg); + + .app-header h1 { + font-size: 2rem; + } + + .cart-container, + .shipping-container { + padding: 1.5rem; + } + + .purchase-button { + padding: 0.875rem 2rem; + font-size: 1rem; } } diff --git a/src/App.js b/src/App.js index c4b1370b..3e1b17b1 100644 --- a/src/App.js +++ b/src/App.js @@ -15,16 +15,26 @@ function App(props) { return ( <>
Thank you for shopping with us!
+Items: ${(itemTotal/100).toFixed(2)}
-Shipping: ${(props.shippingCost/100).toFixed(2)}
-Tax: ${(tax/100).toFixed(2)}
++ Items: + ${(itemTotal/100).toFixed(2)} +
++ Shipping: + ${(props.shippingCost/100).toFixed(2)} +
++ Tax: + ${(tax/100).toFixed(2)} +
Order Total: ${(total/100).toFixed(2)}
++ Order Total: + ${(total/100).toFixed(2)} +