_modal.scss 6.1 KB
Newer Older
1
#lean_overlay {
2 3 4 5 6 7 8 9 10
  @include background-image(radial-gradient(circle at 50% 30%, $shadow-d1, $shadow-d2));

  display: none;
  height:100%;
  left: 0;
  position: fixed;
  top: 0;
  width:100%;
  z-index: 100;
11 12 13
}

.modal {
14 15 16 17 18 19 20 21 22 23
  @include span(5);

  z-index: z-index(mid-front);
  display: none;
  position: absolute;
  left: 50%;
  padding: 8px;
  border-radius: 3px;
  box-shadow: 0 0 5px 0 $shadow-d1;
  background: $gray-d2;
24
  color: $body-color;
25 26

  .inner-wrapper {
27
    z-index: z-index(mid-front);
28 29
    background: $modal-bg-color;
    border-radius: 0;
30
    border: 1px solid $border-color;
31 32 33 34 35 36 37 38 39 40 41
    box-shadow: inset 0 1px 0 0 $white-opacity-70;
    overflow: hidden;
    padding-left: ($baseline/2);
    padding-right: ($baseline/2);
    padding-bottom: ($baseline/2);
    position: relative;

    p {
      font-size: font-size(small);
      line-height: 1.4;
    }
42

43 44 45 46 47 48
    a {
      &:hover,
      &:focus {
        text-decoration: underline;
      }
    }
49

50 51 52 53 54 55
    header {
      z-index: z-index(mid-front);
      margin-bottom: ($baseline*1.5);
      overflow: hidden;
      padding: 28px $baseline 0;
      position: relative;
56

57 58 59
      &::before {
        @include background-image(
          radial-gradient(
60
            50% 50%, circle closest-side,
AlasdairSwan committed
61 62
                        $white-opacity-80 0%,
                        $white-transparent 100%
63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
                   )
               );

        content: '';
        display: block;
        height: 400px;
        left: 0;
        margin: 0 auto;
        position: absolute;
        top: -140px;
        width: 100%;
        z-index: z-index(base);
      }

      hr {
        @include background-image(
          linear-gradient(
80
            180deg,
AlasdairSwan committed
81 82 83
                        $white-transparent 0%,
                        $white-opacity-80 50%,
                        $white-transparent
84 85 86 87 88 89 90 91 92 93 94 95 96
                   )
               );

        height: 1px;
        width: 100%;
        border: none;
        margin: 0;
        position: relative;
        z-index: z-index(base);

        &::after {
          @include background-image(
            linear-gradient(
97
              180deg,
AlasdairSwan committed
98 99 100
                            $light-grey-transparent 0%,
                            $light-grey-solid 50%,
                            $light-grey-transparent
101 102 103 104 105 106 107 108 109 110
                       )
                   );

          height: 1px;
          width: 100%;
          bottom: 0;
          content: '';
          display: block;
          position: absolute;
          top: -1px;
111
        }
112
      }
113

114 115
      h2 {
        @extend .hd-4;
116

117 118 119 120 121 122 123 124
        position: relative;
        text-align: center;
        text-shadow: 0 1px $white-opacity-40;
        z-index: z-index(base);
        font-family: $font-family-serif;

        .edx {
          text-transform: none;
125
        }
126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145
      }
    }

    .modal-form-error {
      background: palette(error, back);
      border: 1px solid palette(error, accent);
      color: palette(error, text);
      display: none;
      margin-bottom: $baseline;
      padding: 12px;
    }

    .notice {
      background: $yellow;
      border: 1px solid darken($yellow, 60%);
      color: darken($yellow, 60%);
      display: none;
      margin-bottom: $baseline;
      padding: 12px;
    }
146

147 148
    .activation-message, .message {
      padding: 0 ($baseline*2) ($baseline/2);
149

150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174
      p {
        margin-bottom: ($baseline/2);
      }
    }

    form {
      margin-bottom: 12px;
      padding: 0 ($baseline*2) $baseline;
      position: relative;
      z-index: 2;

      .input-group {
        @include clearfix();

        border-bottom: 1px solid palette(grayscale, back);
        box-shadow: 0 1px 0 0 $white-opacity-60;
        margin-bottom: ($baseline*1.5);
        padding-bottom: ($baseline/2);
      }

      label {
        color: $text-color;
        font: {
          family: $font-family-serif;
          style: italic;
175 176
        }

177 178 179 180 181 182 183 184 185 186 187
        line-height: 1.6;

        &.field-error {
          display: block;
          color: palette(error, text);

          + input,
          + textarea {
            border: 1px solid palette(error, accent);
            color: palette(error, text);
          }
188
        }
189
      }
190

191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223
      input[type="checkbox"] {
        @include margin-right($baseline/4);
      }

      textarea {
        background: $white;
        display: block;
        height: 45px;
        margin-bottom: $baseline;
        width: 100%;
      }

      input[type="email"],
      input[type="text"],
      input[type="password"] {
        background: $white;
        display: block;
        height: 45px;
        margin-bottom: $baseline;
        width: 100%;
      }

      .submit {
        padding-top: ($baseline/2);

        input[type="submit"] {
          @extend .btn-brand;

          display: block;
          height: auto;
          margin: 0 auto;
          width: 100%;
          white-space: normal;
224
        }
225
      }
226 227
    }

228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254
    .close-modal {
      @include transition(all 0.15s ease-out 0s);

      border-radius: 2px;
      cursor: pointer;
      display: inline-block;
      padding: 10px;
      position: absolute;
      right: 2px;
      top: 0;
      z-index: z-index(front);
      color: $lighter-base-font-color;
      font: {
        size: font-size(large);
        family: $font-family-sans-serif;
      }

      line-height: 1;
      text-align: center;
      border: none;
      background: transparent;
      text-shadow: none;
      letter-spacing: 0;
      text-transform: none;

      &:hover,
      &:focus {
255
        color: $body-color;
256 257 258 259 260 261 262 263 264
        text-decoration: none;
        opacity: 0.8;
      }

      &:focus {
        border: none !important;
      }
    }
  }
265

266 267 268 269
  #help_wrapper,
  #feedback_form_wrapper,
  .discussion-alert-wrapper {
    padding: 0 ($baseline*1.5) ($baseline*1.5);
270

271 272 273 274 275
    header {
      @include padding-left(0);
      @include padding-right(0);

      margin-bottom: $baseline;
276 277
    }

278 279 280 281 282 283 284 285 286
    .note {
      font: {
        size: font-size(x-small);
        family: $font-family-sans-serif;
      }

      line-height: 1.475;
      margin-top: ($baseline/2);
      color: $lighter-base-font-color;
287
    }
288 289 290 291 292 293 294
  }

  .tip {
    font-size: font-size(x-small);
    display: block;
    color: $dark-gray;
  }
295 296 297
}

.leanModal_box {
298
  @extend .modal;
299
}