/* --------------------------------------------
   Fonts and Base Styles
-------------------------------------------- */
@import url(//fonts.googleapis.com/css?family=Ubuntu);

body {
    margin: 0;
    padding: 0;
    font-family: helvetica, sans-serif;
    background-color: #E5F7FF;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Ubuntu', sans-serif;
    font-weight: normal;
}

a {
    text-decoration: none;
    color: #0d6efd;
}

a:hover {
    color: #77b6e2;
}

a.button, input[type="submit"] {
    color: #fff;
    background: #0d6efd;
    border-radius: 4px;
    padding: 10px 20px;
    font-size: 14px;
    border: 0;
}

a.button.light {
    color: #666;
    background: #ededed;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.blue-4 {
    color: #5993bb;
    font-weight: 600;
    font-size: x-large;
}

/* --------------------------------------------
    User Profile Page 
-------------------------------------------- */

.profile-pic {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
}

.no-photo {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background-color: #e0e0e0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  font-size: 0.9rem;
}


/* --------------------------------------------
   Table Styles
-------------------------------------------- */
table {
    width: 100%;
    border-spacing: 0;
    border-collapse: collapse;
}

table th, table td {
    text-align: left;
    font-size: 14px;
    padding: 10px;
    margin: 0;
}

tbody tr:nth-child(odd) {
    background: #efefef;
}

tbody tr.subtotal {
    background: #ccc;
}

thead th, tbody tr.total {
    background: #5993bb;
    color: #fff;
    font-weight: bold;
}

table.cart {
    margin-bottom: 40px;
}

table.cart img {
    width: 180px;
}

tbody td.num {
    text-align: right;
}

td input[type="submit"] {
    font-size: 12px;
    padding: 4px 10px;
}

/* --------------------------------------------
   Form Styles
-------------------------------------------- */
form p label, form p input {
    float: left;
    clear: both;
}

form p label {
    font-size: 14px;
    padding-bottom: 4px;
}

form p input {
    width: 300px;
    font-size: 13px;
    margin-bottom: 10px;
    padding: 10px 12px;
    border: 0;
    background: #efefef;
    color: #666;
    border-radius: 4px;
}

ul.errorlist {
    float: left;
    color: #ff0000;
    clear: both;
    font-size: 13px;
    margin: 0 0 0 10px;
    padding: 10px 0;
}

/* --------------------------------------------
   Header & Subheader
-------------------------------------------- */
#header {
    padding: 10px 100px;
    font-size: 18px;
    overflow: auto;
}

#subheader {
    background: #ececec;
    color: #444;
    padding: 15px 100px;
    overflow: auto;
}

#header .logo {
    font-family: 'Ubuntu', sans-serif;
    float: left;
    color: #333;
    font-size: 22px;
    margin-right: 10%;
}

#subheader .cart {
    float: right;
    padding-top: 4px;
}

/* --------------------------------------------
   Hero Section Styles
-------------------------------------------- */
.hero-image {
  position: relative;
  margin: 0;
  overflow: hidden; /* ensures nothing spills out */
}

.hero-image img {
  width: 100%;
  max-height: 500px; /* adjust this */
  object-fit: cover;
  object-position: center center;
  display: block;
}

.hero-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  color: white;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 0.5rem;
  padding: 1rem 2rem;
  text-align: center;
}

/* --------------------------------------------
   Layout: Content, Main
-------------------------------------------- */
#content {
    padding: 0 100px;
    overflow: hidden;
}

#main {
    width: 100%;
    margin-right: 0;
    overflow: hidden;
}

/* --------------------------------------------
   Product List & Details
-------------------------------------------- */
.product-list .item {
    width: 25%;
    padding: 10px 20px 10px 0;
    float: left;
    text-align: center;
    line-height: 1.2;
}

.product-list .item img {
    width: 100%;
    height: 170px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
}

.product-list.list .item {
    background: white;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.1);
}

.product-detail {
    text-align: justify;
}

.product-detail .price {
    color: #333;
    font-size: 28px;
    font-weight: bold;
}

.product-detail img {
    width: 40%;
    float: left;
    padding: 0 20px 20px 0;
}

.product-detail h1 {
    margin-bottom: 0;
}

.product-detail h2 {
    margin-top: 10px;
}

/* --------------------------------------------
   Order Form & Info
-------------------------------------------- */
.order-form {
    float: left;
}

.order-info {
    float: right;
    width: 300px;
    background: #efefef;
    padding: 10px 20px;
    color: #333;
    border-bottom: 4px solid #5993bb;
}

.order-info h3 {
    color: #5993bb;
}

.order-info ul li {
    margin: 0;
    padding: 0;
    font-size: 14px;
}

.order-info p {
    font-weight: bold;
    float: right;
}

.order-info span {
    float: right;
}

.neg {
    color: #dc1616;
}

/* Makes the placeholder look muted */
select:invalid,
select option[value=""] {
    color: #6c757d;
}

/* --------------------------------------------
   Bootstrap Card Image Fixes
-------------------------------------------- */
.card img {
    width: 100%;
    height: 200px !important;
    object-fit: cover;
    min-height: 200px !important;
}

.card {
    height: 100%;
}

.card-body {
    display: flex;
    flex-direction: column;
}

.card-text {
    flex-grow: 1;
}

/* Override any conflicting Bootstrap styles */
.card .img-fluid {
    height: 200px !important;
    object-fit: cover;
}

/* --------------------------------------------
   Braintree Hosted Fields
-------------------------------------------- */
form div.field {
    font-size: 13px;
    color: #c41010;
    width: 300px;
    height: 22px;
    margin-bottom: 10px;
    padding: 6px 12px;
    border: 0;
    background: #efefef;
    border-radius: 4px;
}

/* --------------------------------------------
   Media Queries
-------------------------------------------- */
@media (max-width: 767.98px) {
    /* Stack cards vertically on mobile */
    .card .row {
        flex-direction: column;
    }
    
    /* Make image full width on mobile */
    .card .col-md-4,
    .card .col-md-8 {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    /* Adjust image height for mobile */
    .card img {
        height: 250px !important;
        border-radius: 0.375rem 0.375rem 0 0 !important;
    }
    
    /* Increase text sizes for mobile */
    .card-title {
        font-size: 1.4rem !important;
    }
    
    .card-text {
        font-size: 1rem !important;
    }
    
    .h4 {
        font-size: 1.3rem !important;
    }
    
    /* Adjust button size and prevent wrapping */
    .btn {
        padding: 0.6rem 1.2rem !important;
        font-size: 1rem !important;
        min-width: 120px !important;
        white-space: nowrap !important;
    }
    
    /* Adjust container padding */
    #content {
        padding: 0 20px !important;
    }
    
    #main h1 {
        font-size: 2rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    .card {
        margin-bottom: 1.5rem !important;
    }
    
    .card-body {
        padding: 1.5rem !important;
    }
}

@media (max-width: 480px) {
    .card img {
        height: 200px !important;
    }
    
    .card-title {
        font-size: 1.2rem !important;
    }
    
    .card-body {
        padding: 1rem !important;
    }
    
    #content {
        padding: 0 15px !important; /* Slightly less padding for very small screens */
    }
}
